cache and Widget

I am trying to use Caching "library" of Yii.

I use the file extension (Fragment Caching related with dependencies) for someviews of the  site.

I also want to use Caching for the Widgets (menus mainly) of the site, I will do the some as the main views at the views of Widgets?.

<?php if($this->beginCache($id, array('requestTypes'=>array('GET')))) { ?>


...content to be cached...


<?php $this->endCache(); } ?>

what is your question?

The question is that if all will be ok if I use this code at the view of the  Widget.

<?php if($this->beginCache($id, array('requestTypes'=>array('GET')))) { ?>


...content to be cached...


<?php $this->endCache(); } ?>

I ha

Of course. You can use output cache in both controller view and widget view.