Home »
FUDforum Development »
Bug Reports »
Possible bug in compiler.inc
Possible bug in compiler.inc [message #30728] |
Fri, 10 March 2006 21:24 |
Abraxa
Messages: 72 Registered: August 2004 Location: Germany
Karma:
|
Member |
|
|
Heya =)
In a custom CSS template I was using {FULL_ROOT}{THEME_IMAGE_ROOT}/blabla.gif as a property - which worked with 2.6.3 but isn't working with 2.7.4 anymore. I was looking into why that is and saw that now FULL_ROOT isn't an URL anymore but instead just a PHP variable reference to WWW_ROOT.
So I looked into compiler.inc to find an alternative to FULL_ROOT that I could use and I found the following:
in compile_all():
$cmpl =& $GLOBALS['__COMPILER__'];
$cmpl['FULL_ROOT'] = $GLOBALS['WWW_ROOT']{strlen($GLOBALS['WWW_ROOT']) - 1} == '/' ? $GLOBALS['WWW_ROOT'] : $GLOBALS['WWW_ROOT'].'/';
in resolve_sections():
case 'FULL_ROOT':
$ret .= "'.\$GLOBALS['WWW_ROOT'].'";
break;
case 'ROOT':
case 'THEME_ROOT':
case 'THEME_IMAGE_ROOT':
$ret .= $GLOBALS['__COMPILER__'][$tag];
break;
Since $GLOBALS['__COMPILER__']['FULL_ROOT'] gets set in compile_all()... why isn't it used just like ROOT, THEME_ROOT and THEME_IMAGE_ROOT?
Did you merely forget to make the change for FULL_ROOT as well or is there a reason why you're replacing FULL_ROOT by a reference of WWW_ROOT instead of using $GLOBALS['__COMPILER__']['FULL_ROOT']?
-Soeren
|
|
|
Goto Forum:
Current Time: Tue Nov 26 08:58:04 GMT 2024
Total time taken to generate the page: 0.04610 seconds