Skip to content
Browse files

Merge pull request #1540 from creocoder/chtml-cssfile-fix

Fixed CHtml::cssFile() ignore CHtml::$closeSingleTags
  • Loading branch information...
2 parents be5241d + 5e739cb commit 967edc0fd894680690d7ace314821bfcff2c3ca8 @samdark samdark committed Oct 6, 2012
Showing with 1 addition and 3 deletions.
  1. +1 −3 framework/web/helpers/CHtml.php
View
4 framework/web/helpers/CHtml.php
@@ -270,9 +270,7 @@ public static function refresh($seconds, $url='')
*/
public static function cssFile($url,$media='')
{
- if($media!=='')
- $media=' media="'.$media.'"';
- return '<link rel="stylesheet" type="text/css" href="'.self::encode($url).'"'.$media.' />';
+ return CHtml::linkTag('stylesheet','text/css',self::encode($url),$media!=='' ? $media : null);
}
/**

0 comments on commit 967edc0

Please sign in to comment.
Something went wrong with that request. Please try again.