Yii Framework Forum: modify css - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

modify css Rate Topic: -----

#1 User is offline   riccardo 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 40
  • Joined: 02-March 10

Posted 17 March 2010 - 04:46 AM

Hi,

how can i use a new css for an application controller views?

I saw that in the css directory there are some css files but i think they are application related...

Thanks,
Riccardo
0

#2 User is offline   andy_s 

  • Random Member Title
  • Yii
  • Group: Moderators
  • Posts: 1,526
  • Joined: 22-June 09
  • Location:Russia, Kostroma

Posted 17 March 2010 - 05:34 AM

If you want to register a css file for a special controller, then you can do it in it's init() method:

public function init()
{
    parent::init();

    Yii::app()->clientScript->registerCssFile(Yii::app()->baseUrl.'/css/my.css');
}


But you can also modify all files in the css directory. That is what they are for :)
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users