Problems with eval
Posted: Sat Feb 21, 2004 9:27 pm
I'm trying to get Vbulletin code to work properly.
I'm having a problem with the eval function in the admin/options.php file in vbulletin.
eval ("echo \"$setting[optioncode]\";");
produces this error:
"Parse error: parse error, expecting `','' or `';'' in /usr/local/apache/htdocs/vbulletin/admin/options.php(72) : eval()'d code on line 2"
If I change the inner quote marks to singles:
eval ("echo '$setting[optioncode]';");
then I lose the error message but some of the source code html does not print correctly, for instance it prints out some php code where instead there should be html such as:
<select name=\"setting[$setting[settingid]]\">
Any idea on how to get the eval function working properly so that I no longer get error messages and it prints out html correctly.
Thanks,
oohkumar
I'm having a problem with the eval function in the admin/options.php file in vbulletin.
eval ("echo \"$setting[optioncode]\";");
produces this error:
"Parse error: parse error, expecting `','' or `';'' in /usr/local/apache/htdocs/vbulletin/admin/options.php(72) : eval()'d code on line 2"
If I change the inner quote marks to singles:
eval ("echo '$setting[optioncode]';");
then I lose the error message but some of the source code html does not print correctly, for instance it prints out some php code where instead there should be html such as:
<select name=\"setting[$setting[settingid]]\">
Any idea on how to get the eval function working properly so that I no longer get error messages and it prints out html correctly.
Thanks,
oohkumar