Index: branches/5.1.x/core/units/themes/themes_tag_processor.php =================================================================== diff -u -N -r13086 -r13545 --- branches/5.1.x/core/units/themes/themes_tag_processor.php (.../themes_tag_processor.php) (revision 13086) +++ branches/5.1.x/core/units/themes/themes_tag_processor.php (.../themes_tag_processor.php) (revision 13545) @@ -1,6 +1,6 @@ getObject($params); - if (!$object->GetDBField('StyleName')) { - // no stylesheet is associated with current theme - return ''; - } + // not using theme-based stylesheets anymore + trigger_error('Tag "StylesheetFile" is depricated and should not be used.', E_USER_NOTICE); - $css_url = $this->Application->BaseURL(WRITEBALE_BASE . '/stylesheets'); - $css_path = rtrim( str_replace( $this->Application->BaseURL(), FULL_PATH . '/', $css_url), '/' ); - - $last_compiled = $object->GetDBField('LastCompiled'); - - $style_name = mb_strtolower( $object->GetDBField('StyleName') ); - - if( file_exists($css_path.'/'.$style_name.'-'.$last_compiled.'.css') ) - { - $ret = rtrim($css_url, '/').'/'.$style_name.'-'.$last_compiled.'.css'; - - } - else - { - // search for previously compiled stylesheet - $last_compiled = 0; - if( $dh = opendir($css_path) ) - { - while( ($file = readdir($dh)) !== false ) - { - if( preg_match('/(.*)-([\d]+).css/', $file, $rets) ) - { - if( $rets[1] == $style_name && $rets[2] > $last_compiled ) $last_compiled = $rets[2]; - } - } - closedir($dh); - } - if ($last_compiled) { - // found - $ret = $css_url.'/'.$style_name.'-'.$last_compiled.'.css'; - } - else { - // not found - return ''; - } - } - - if (isset($params['file_only'])) return $ret; - - return ''; + return ''; } function SelectedTheme($params)