Fix IMGDIR/CSSDIR when no config.php yet and creating setting to disable remoteurls for sflogo
This commit is contained in:
parent
a1cfa2f60c
commit
869b9be7e9
@ -107,6 +107,10 @@ class Config {
|
|||||||
'desc'=>'Group DN, where membership will exempt the users from readonly attrs',
|
'desc'=>'Group DN, where membership will exempt the users from readonly attrs',
|
||||||
'default'=>null);
|
'default'=>null);
|
||||||
|
|
||||||
|
$this->default->appearance['remoteurls'] = array(
|
||||||
|
'desc'=>'Whether to include renders for remote URLs',
|
||||||
|
'default'=>true);
|
||||||
|
|
||||||
$this->default->appearance['timezone'] = array(
|
$this->default->appearance['timezone'] = array(
|
||||||
'desc'=>'Define our timezone, if not defined in php.ini',
|
'desc'=>'Define our timezone, if not defined in php.ini',
|
||||||
'default'=>null);
|
'default'=>null);
|
||||||
|
@ -2518,7 +2518,7 @@ function get_href($type,$extra_info='') {
|
|||||||
case 'forum':
|
case 'forum':
|
||||||
return sprintf('%s/mailarchive/forum.php?forum_name=%s',$sf,$forum_id);
|
return sprintf('%s/mailarchive/forum.php?forum_name=%s',$sf,$forum_id);
|
||||||
case 'logo':
|
case 'logo':
|
||||||
return sprintf('http://sflogo.sourceforge.net/sflogo.php?group_id=%s&type=8',$group_id);
|
return isset($_SESSION) && ! $_SESSION[APPCONFIG]->getValue('appearance','remoteurls') ? '' : sprintf('http://sflogo.sourceforge.net/sflogo.php?group_id=%s&type=8',$group_id);
|
||||||
case 'sf':
|
case 'sf':
|
||||||
return sprintf('%s/projects/phpldapadmin',$sf);
|
return sprintf('%s/projects/phpldapadmin',$sf);
|
||||||
case 'web':
|
case 'web':
|
||||||
|
@ -31,6 +31,12 @@ class page {
|
|||||||
if (defined('DEBUG_ENABLED') && DEBUG_ENABLED)
|
if (defined('DEBUG_ENABLED') && DEBUG_ENABLED)
|
||||||
debug_log('Entered with [%s]',129,__FILE__,__LINE__,__METHOD__,$index);
|
debug_log('Entered with [%s]',129,__FILE__,__LINE__,__METHOD__,$index);
|
||||||
|
|
||||||
|
# If we done have a configuration, then our IMGDIR and CSS are not defined
|
||||||
|
if (! defined('IMGDIR'))
|
||||||
|
define('IMGDIR','images/default');
|
||||||
|
if (! defined('CSSDIR'))
|
||||||
|
define('CSSDIR','css/default');
|
||||||
|
|
||||||
$this->index = $index;
|
$this->index = $index;
|
||||||
|
|
||||||
# To be defined in a configuration file.
|
# To be defined in a configuration file.
|
||||||
@ -324,7 +330,7 @@ class page {
|
|||||||
printf('<tr class="foot"><td><small>%s</small></td><td colspan=2><div id="ajFOOT">%s</div>%s</td></tr>',
|
printf('<tr class="foot"><td><small>%s</small></td><td colspan=2><div id="ajFOOT">%s</div>%s</td></tr>',
|
||||||
isCompress() ? '[C]' : ' ',
|
isCompress() ? '[C]' : ' ',
|
||||||
app_version(),
|
app_version(),
|
||||||
sprintf('<a href="%s"><img src="%s" border="0" alt="SourceForge.net Logo" /></a>',get_href('sf'),get_href('logo')));
|
get_href('logo') ? sprintf('<a href="%s"><img src="%s" border="0" alt="SourceForge.net Logo" /></a>',get_href('sf'),get_href('logo')) : ' ');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user