Changeset 2273
- Timestamp:
- 03/16/10 18:27:59 (14 years ago)
- Location:
- trunk/phpgwapi
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/phpgwapi/inc/class.common.inc.php
r2269 r2273 1255 1255 * @author Dave Hall (*based* on verdilak? css inclusion code) 1256 1256 */ 1257 function get_css( )1257 function get_css( ) 1258 1258 { 1259 1259 $tpl = createObject('phpgwapi.Template', $this->get_tpl_dir('phpgwapi')); … … 1279 1279 if ( @ isset( $GLOBALS[ 'phpgw_info' ][ 'flags' ][ 'currentapp' ] ) ) 1280 1280 { 1281 $css = "/ {$GLOBALS[ 'phpgw_info' ][ 'flags' ][ 'currentapp' ]}/templates/%s/%s.css";1281 $css = "/%s/templates/%s/%s.css"; 1282 1282 1283 1283 global $path, $link, $template; … … 1292 1292 $template = $GLOBALS[ 'phpgw_info' ][ 'server' ][ 'template_set' ]; 1293 1293 1294 function _css( $ css )1294 function _css( $module, $css ) 1295 1295 { 1296 1296 global $link, $path, $template; 1297 if ( file_exists( sprintf( $path, $template, str_replace( '/', SEP, $css ) ) ) ) 1298 return sprintf( $link, $template, $css ); 1299 1300 if ( file_exists( sprintf( $path, 'default', str_replace( '/', SEP, $css ) ) ) ) 1301 return sprintf( $link, 'default', $css ); 1297 1298 error_log( sprintf( $path, $module, $template, str_replace( '/', SEP, $css ) ) . "\n", 3, '/tmp/log' ); 1299 1300 if ( file_exists( sprintf( $path, $module, $template, str_replace( '/', SEP, $css ) ) ) ) 1301 return sprintf( $link, $module, $template, $css ); 1302 1303 if ( file_exists( sprintf( $path, $module, 'default', str_replace( '/', SEP, $css ) ) ) ) 1304 return sprintf( $link, $module, 'default', $css ); 1302 1305 1303 1306 return ''; 1304 1307 } 1305 1308 1306 $css = _css( 'app' ); 1307 $css .= _css( "css/{$GLOBALS[ 'phpgw_info' ][ 'user' ][ 'preferences' ][ 'common' ][ 'theme' ]}" ); 1309 $css = _css( 'phpgwapi', "css/{$GLOBALS[ 'phpgw_info' ][ 'user' ][ 'preferences' ][ 'common' ][ 'theme' ]}" ); 1310 $css .= _css( $GLOBALS[ 'phpgw_info' ][ 'flags' ][ 'currentapp' ], 'app' ); 1311 $css .= _css( $GLOBALS[ 'phpgw_info' ][ 'flags' ][ 'currentapp' ], "css/{$GLOBALS[ 'phpgw_info' ][ 'user' ][ 'preferences' ][ 'common' ][ 'theme' ]}" ); 1308 1312 1309 1313 if ( $css ) -
trunk/phpgwapi/templates/classic/head.tpl
r1151 r2273 13 13 <link rel="icon" href="{img_icon}" type="image/x-ico" /> 14 14 <link rel="shortcut icon" href="{img_shortcut}" /> 15 <link href="{theme_css}" title="eGroupWareStyle" type="text/css" rel="StyleSheet"/>16 15 <META http-equiv="Default-Style" content="eGroupWareStyle"> 17 16 {slider_effects} -
trunk/phpgwapi/templates/default/head.inc.php
r890 r2273 33 33 34 34 #_debug_array($GLOBALS['phpgw_info']['user']['preferences']['common']); 35 $theme_css = ".".$GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/'.$GLOBALS['phpgw_info']['server']['template_set'].'/css/'.$GLOBALS['phpgw_info']['user']['preferences']['common']['theme'].'.css';36 if(!file_exists($theme_css))37 {38 $theme_css = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/'.$GLOBALS['phpgw_info']['server']['template_set'].'/css/'.$GLOBALS['phpgw_info']['user']['preferences']['common']['theme'].'.css';39 }40 35 41 36 //pngfix defaults to yes … … 94 89 'website_title' => $GLOBALS['phpgw_info']['server']['site_title'].$app, 95 90 'body_tags' => $bodyheader .' '. $GLOBALS['phpgw']->common->get_body_attribs(), 96 'theme_css' => $theme_css,97 91 'css' => $GLOBALS['phpgw']->common->get_css(), 98 92 'java_script' => $GLOBALS['phpgw']->common->get_java_script(), -
trunk/phpgwapi/templates/default/head.tpl
r1247 r2273 13 13 <link rel="icon" href="{img_icon}" type="image/x-ico" /> 14 14 <link rel="shortcut icon" href="{img_shortcut}" /> 15 <link href="{theme_css}" title="eGroupWareStyle" type="text/css" rel="StyleSheet"/>16 15 <META http-equiv="Default-Style" content="eGroupWareStyle"> 17 16 {slider_effects}
Note: See TracChangeset
for help on using the changeset viewer.