PDA

View Full Version : Receiving parse error for functions_showthread


carolmyt
05-11-2005, 03:10 PM
I'm receiving the following when trying to view a thread:
Parse error: parse error, expecting `T_STRING' or `T_VARIABLE' or `T_NUM_STRING' in /var/www/html/includes/functions_showthread.php(640) : eval()'d code on line 64

(which repeats 10 times in the header)

and
Unable to add cookies, header already sent.
on the page.

Lines 63, 64 and 65 are:
eval('$userinfo[\'icqicon\'] = "' . fetch_template('im_icq') . '";');
$userinfo['showicq'] = true;
$show['hasimicons'] = true;

I have no idea what's going on, reloading old files isn't helping. Please help! ;)

ice9
05-11-2005, 04:03 PM
First thing I would do is double-check the syntax for single quotes, double quotes, and escaped characters within an eval statement.

carolmyt
05-11-2005, 04:24 PM
That's not it.

Zero Tolerance
05-17-2005, 07:46 AM
Usually happens when there is an error in the templates, and using the eval() throws an error back because the purpose is to change a string and parse it as syntax, so to speak.

The common error in templates is:
$variable['param']
When it should be:
$variable[param]
OR
{$variable['param']}

And ofcourse the template the error is contained in would be 'im_icq' :)

- Zero Tolerance