Yii Method for importing CSS

Source: Internet
Author: User

The position of the CSS file imported in layout should be before the <title> tag,You can insert CSS into a view and import it directly in the view.


In this way, the CSS file in the view file will be inserted between laoyout and <title>.

If you insert CSS under <title> in layout, the CSS in view will only be overwritten.


reference:

http://www.yiiframework.com/forum/index.php/topic/16804-%E5%8F%98%E6%80%81%E6%96%B9%E6%B3%95%E8%A7%A3%E5%86%B3css%E9%A1%BA%E5%BA%8F%E9%97% AE %E9%A2%98/page__p__139307__hl__c+#entry139307


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.