Module Unable to Publish Assets Directory


class BlogModule extends CWebModule


  public function init()


    // this method is called when the module is being created

    // you may place code here to customize the module or the application

    $assetsDirectory = Yii::app()->assetManager->publish(Yii::getPathOfAlias('blog.assets'));

    Yii::app()->clientScript->registerCssFile($assetsDirectory . '/css/blog.css');

    // import the module-level models and components




      // 3rd party extensions




  public function beforeControllerAction($controller, $action)


    if (parent::beforeControllerAction($controller, $action))


      // this method is called before any module controller action is performed

      // you may place customized code here

      return true;



      return false;







Nothing gets moved to the base application assets directory even though it looks like it has completely successfully. Any ideas?

I am having the same issue with an extension I downloaded.

Care to share what extension it is?

Hi, I have had this issue in the past and clearing my /assets directory has fixed it for me. Hope this helps.

PS: By /assets directory I mean the base /assets folder that is populated by AssetManager.