By maxbayes on
Hi
I just installed drupal and on running it for the first time get the following error:
"Parse error: parse error, unexpected $ in /var/www/html/drupal/modules/user.module on line 1981"
I read that the problem might be with a blank line, but its not the case.
[root@max modules]# tail -1 user.module
?>
[root@max modules]# wc -l user.module
1980 user.module
I'm not too familiar with php so can someone give me any hints as to whats happening.
Thanks.
Max
Comments
what version of Drupal?
...are you using?
Re: what version of Drupal?
I'm using drupal-4.0.0
I found the problem
in my case was php short tags. When I installed locally for testing I got the same error. I have short tags off on my server.
I had to do a find/replace all instances of <? short tags with <?php long tags. The errors in a default v4 install are to be found in:
modules/user.module
Lines 1722, 1760, 1932, 1978
themes/goofy/goofy.theme
Line 179
Alternatively, add
php_value short_open_tag on
to your .htaccess file and you're set.
Fixed. Thanks.
I fixed this in CVS and backported it to both 4.1.0-rc and 4.0.0. There were additional short tags in 3 other files you might have forgotten. Thanks.