Error on Installation
modctek - September 2, 2008 - 04:38
| Project: | Masquerade |
| Version: | 6.x-1.0-beta1 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | duplicate |
Jump to:
Description
Tried installing the beta version on a relatively clean D6 install and got the following error:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /home/modctek1/public_html/room4/sites/all/modules/masquerade/masquerade.module on line 249
Had to go in and disable via phpMyAdmin.

#1
I haven't reproduced it yet, but this might help. Replace line 249 with
$user = user_load(array('uid' => $switch_user));$user_name = $user->name;
unset($user);
if that doesn't work, please report back the results of replacing 249 with (don't do this on a live site)
die(var_dump($switch_user, user_load(array('uid' => $switch_user))));If you can't/don't want to do either of those, please tell me which version of PHP you're running.
#2
The error occurred under PHP 4.4.7. I'm going to attempt an upgrade to PHP5 and see if it still throws the error.
#3
It's an chained-object operation that is not supported in PHP 4. This is a duplicate of #285472: Parse error with PHP 4: same line of code, different versions.