Paying attention to this line:
Also if I use !isset it returns true with a null value for $theme
Well this is clear in the manual:
isset() will return FALSE if testing a variable that has been set to NULL
So !isset($a_Null) = !FALSE = TRUE
From PHP Manual
=
$var = 0;
if
if (isset($theme)) {
print(Current theme is $theme);
require content/header_$theme.php;
if you try to send headers in header_$theme.php, this wont work, because
you can't send headers after you've printed or echoed something.
try this:
if (isset($theme)) {
require
I've tried...print nothing in my browser then it seems to me correct.
The condition ELSE is satisfied.
bye.
codeused:
if (isset($theme)) {
print(Current theme is $theme);
require content/header_$theme.php;
} else {
print($theme);
require content/header.php;
}
codeused.
Bobb [EMAIL
3 matches
Mail list logo