1 nsanden Dec 22, 2005 04:40
3 blueyed Dec 23, 2005 01:38
That must be another error.
I could only find one occasion with the filemanager, where it used this "case 'default'" and the $action cannot have this value.
In /install/index.php $action (which gets used for the switch) really is a string with value 'default' by default.
I've used PHP 5.0.5 by myself quite some time. I even use it locally still and this error does not happen. Going to /blogs/install/index.php does not give me an empty place where the main content should be.
4 nsanden Dec 23, 2005 02:30
Ah your right, I just assumed there wasn't a real $action = 'default' but now i see it or what i'm guessing does it "param( 'action', 'string', 'default' );"
If i echo out $action right after that line in /install/index.php nothing is echoed on php 5.0.5 but in 5.0.3 it does echo 'default'.
So I guess i'll look into that function next. Strange it would work for you with the same php version though.
By the way though, doing a search for case 'default' i found quite a few occurances...
[root@www root]# grep -n -I -R -i "case 'default'" /var/www/html/pugetsystems/blog/
/var/www/html/pugetsystems/blog/admin/files.php:716: case 'default':
/var/www/html/pugetsystems/blog/admin/blogs.php:501: case 'default':
/var/www/html/pugetsystems/blog/admin/_blogs_general.form.php:41: case 'default':
/var/www/html/pugetsystems/blog/evocore/_blog.class.php:290: case 'default':
/var/www/html/pugetsystems/blog/evocore/_blog.class.php:342: case 'default':
/var/www/html/pugetsystems/blog/evocore/_blog.class.php:409: case 'default':
/var/www/html/pugetsystems/blog/install/index.php:275: case 'default':
5 nsanden Dec 23, 2005 03:21
Okay, so not sure why this works BUT...
Line 926ish of /evocore/_misc.funcs.php in the 'param' function reads:
<?php
if( !isset( $$var ) || $override )
?>
If i change that to:
<?php
if( !empty( $$var ) || $override )
?>
All of a sudden it works... Only possible reason for that I can come up with is by using 'global $$var' in that function it actually sets the variable but its still empty? Does that make sense?
The fact that it works in your PHP 5.0.5 and not mine though, leads me to assume its some configuration option, but i don't have the slightest clue what would control how 'isset' works. Maybe you do?
Here's my PHP info http://www.savingadvice.com/phpinfo.php
Any ideas? I'll try installing now and play around with it, see if all the blank pages are gone in the mean time. Easy fix at least!
6 blueyed Dec 23, 2005 15:47
nsanden, are you using the same php.ini version with 5.0.3 and 5.0.5?
Can you please add a
if( $var == 'default' ) pre_dump( $$var );
before the isset() check in param() that you've quoted?
Please post, what your 5.0.3 and 5.0.5 says about it.
7 nsanden Dec 23, 2005 21:54
No, they are different php.ini versions. Infact completely different servers, and probably even different apache versions.
I tried adding that line just before the isset() line for both servers...
Oddly, neither passed the if condition, nothing printed to the screen, (though it seems like at least the 5.0.3 should have). Strange?! Again maybe the global $$var is messing it up, though doesn't seem like it should.
8 blueyed Dec 29, 2005 06:00
nsanden, sorry, the code you should try should actually be:
if( $default == 'default' ) pre_dump( $$var );
So, that if we have 'default' as default (which is the case in /install/index.php) we get the value of the global ($$var).
Put that after the "global" line at the beginning of param() in _misc.funcs.php.
9 nsanden Jan 02, 2006 09:10
Getting a blue box with 'NULL' printed. Nothing more...
10 blueyed Jan 03, 2006 01:48
With both your 5.0.5 and 5.0.3 installations?
Where? On the /install/index.php page?
Then it at least means that you have register_globals turned off.
If i echo out $action right after that line in /install/index.php nothing is echoed on php 5.0.5 but in 5.0.3 it does echo 'default'.
So I guess i'll look into that function next. Strange it would work for you with the same php version though.
It would help alreadyto enable $debug in /conf/_advanced.php and look at the Debuglog category "params", what it says about the "action" param (with your PHP 5.0.5 setup, as 5.0.3 seems to be ok). Also, you might want to go into /evocore/_misc.funcs.php and uncomment/add some more $Debuglog->add() calls and/or just echo/print lines to find the cause.
Thanks for your help!
By the way, I am only assuming it won't work in higher versions. I haven't actually tested it. I did test it on PHP 5.0.3 and it worked fine using that bad CASE syntax.
The strange thing is I didn't see any mention in PHP change logs saying they removed support for that bad syntax. Maybe its just a bug in PHP 5.0.5 who knows. Still I think that syntax is incorrect and couldn't hurt to fix.