Parse error: parse error, unexpected $, expecting ')'

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 06-11-2007, 01:26 PM
Pligg Donor
 
Join Date: Oct 2006
Posts: 52
I started receiving errror message:

Parse error: parse error, unexpected $, expecting ')' in /home/bwannel1/public_html/site/templates_c/c_ef20b2b5fff08f636a080a9108ff9329.php on line 406


over the weekend. Things have been running fine for a while and no changes have been made recently. If I clear the templates_c folder the site works again without any issues. However, some content that is being cached triggers the error again.

I'm running Pligg 9.6 Any ideas on what I could check for?

Last edited by LeoNel; 06-11-2007 at 02:56 PM.
Reply With Quote
  #2 (permalink)  
Old 06-11-2007, 01:37 PM
Casual Pligger
Pligg Version: 995
Pligg Template: Yget
 
Join Date: Sep 2006
Posts: 58
I am having exactly the same problem from time to time, also running Pligg 9.6
Reply With Quote
  #3 (permalink)  
Old 06-11-2007, 01:45 PM
savant's Avatar
Constant Pligger
 
Join Date: Apr 2006
Location: UK
Posts: 1,181
Quote:
/home/bwannel1/public_html/memeza/templates_c/c_ef20b2b5fff08f636a080a9108ff9329.php
This suggests you have an error when you changed the templates

when you get this error again, post the contents of the file.
Reply With Quote
  #4 (permalink)  
Old 07-16-2007, 08:29 PM
Pligg Donor
 
Join Date: Mar 2007
Posts: 85
Quote:
Originally Posted by savant View Post
This suggests you have an error when you changed the templates

when you get this error again, post the contents of the file.
I get this same error - a lot. Clearing the cache doesn't seem to help for long of course. The errors are always these three lines and always the same template fle (language.conf) The errors and the corresponding lines are below:

Parse error: parse error, unexpected $ in /var/www/html/aa/aaa.com/templates_c/c_ef20b2b5fff08f636a080a9108ff9329.php on line 255

line 255: 'PLIGG_Visual_Submit3Errors_BadKey' => 'Incorrect key',

Parse error: parse error, unexpected $ in /var/www/html/aa/aaa.com/templates_c/c_ef20b2b5fff08f636a080a9108ff9329.php on line 392

line 392: 'PLIGG_Visual_Profile_AvatarResize' => 'If the image is larger than 30x30 it will be resized.',


Parse error: parse error, unexpected $, expecting ')' in /var/www/html/aa/aaa.com/templates_c/c_ef20b2b5fff08f636a080a9108ff9329.php on line 136

line 136: 'PLIGG_Visual_Comment_ThisComment' => 'this comment',

Any ideas? Everything looks fine to me in the file. Thanks for any help.
Reply With Quote
  #5 (permalink)  
Old 07-16-2007, 11:31 PM
AshDigg's Avatar
Mayor of PliggVille/Coder
 
Join Date: Dec 2005
Posts: 1,515
When you say "Clearing the cache doesn't seem to help" are you clearing the 'cache' folder or the 'templates_c' folder? You should be clearing the 'templates_c' folder.
Reply With Quote
  #6 (permalink)  
Old 07-17-2007, 12:35 AM
Pligg Donor
 
Join Date: Mar 2007
Posts: 85
Quote:
Originally Posted by AshDigg View Post
When you say "Clearing the cache doesn't seem to help" are you clearing the 'cache' folder or the 'templates_c' folder? You should be clearing the 'templates_c' folder.
I meant the templates_c folder, not the /cache folder.
Reply With Quote
  #7 (permalink)  
Old 07-18-2007, 07:41 PM
Pligg Donor
 
Join Date: Mar 2007
Posts: 85
I'm continuing to see the same 3 errors, all from the same templates_c cache file, which is the cache file for the language.conf file. Sometimes, the error displays above or between parts in the rendered page. At other times, the error is thrown and displays at the top of a completely blank page. Refreshing the page seems to clear the error. Which does not make sense to me at all. And it always comes back. Same 3 errors (one at a time of course).

Thanks for any help.
Reply With Quote
  #8 (permalink)  
Old 07-29-2007, 06:32 AM
New Pligger
 
Join Date: Jul 2007
Location: Poland
Posts: 5
Send a message via Skype™ to marcinmw
Hi

I have similar problem.

I solve it, by changing template to original, and the sending my new template files(not all at once! ). It turns out that something was bad in one of files in my new template. I replace it with the original, and than start making changes from the beginning.

Hope this help.

Last edited by marcinmw; 07-29-2007 at 06:37 AM.
Reply With Quote
  #9 (permalink)  
Old 07-29-2007, 09:33 PM
Pligg Donor
 
Join Date: Mar 2007
Posts: 85
Quote:
Originally Posted by marcinmw View Post
Hi

I have similar problem.

I solve it, by changing template to original, and the sending my new template files(not all at once! ). It turns out that something was bad in one of files in my new template. I replace it with the original, and than start making changes from the beginning.

Hope this help.
Hi Marcin -
Thanks for this - do you know, for the error you recieved, when you trace it to the cache file that refers to a specific template file, is it actually that template file that once corrected, solves the problem?

Since it is the language cache file that is generating the errors, my fear is that it is not necessarily the language file itself that is having the problem, but one of the many template files that uses that conf. file and so I could spend days rebuilding files until getting it right.
Reply With Quote
  #10 (permalink)  
Old 07-30-2007, 12:44 PM
New Pligger
 
Join Date: Jul 2007
Location: Poland
Posts: 5
Send a message via Skype™ to marcinmw
Quote:
Originally Posted by betagirl View Post
Hi Marcin -
Thanks for this - do you know, for the error you recieved, when you trace it to the cache file that refers to a specific template file, is it actually that template file that once corrected, solves the problem?

Since it is the language cache file that is generating the errors, my fear is that it is not necessarily the language file itself that is having the problem, but one of the many template files that uses that conf. file and so I could spend days rebuilding files until getting it right.
Hi,

In my case I have noticed error was probably in header.tpl file. After sending orignial everything get back to norm, so I have made changes again on the orignial file and resend it. So it probably can happen on every template file.

I have changed practicly all my language file because I have translated it into Polish, in my case it has nothing to do with this(probably ).

I've made small investigation, what exactly was causing the error in header.tpl:

First of all I get different errors:

after first reloading of site I get no header (link start, login etc. ), the header was replaced by:

Parse error: parse error, unexpected $ in /srv/www/htdocs/ura157/html/class.template.php(745) : eval()'d code on line 213

and rest of site was ok, after reloading there was only the error:

Parse error: parse error, unexpected $ in /srv/www/htdocs/ura157/html/templates_c/c_c71060b777c38fc5b1c4030b867a0c9d.php on line 213

and nothing more.

So it can be helpful to know in which part of the site the error is showing up.

In my case I have(probably by mistake) erase the line

» {$navbar_where.text4}{/if}

in original it's in the line 69 of header.tpl.
Everything in Pligg beta 9.7.

It can be helpful to have some tool to comparing files, under linux I have "Kompare" - very good stuff.

Hope this will help you.

Last edited by marcinmw; 07-30-2007 at 01:11 PM.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Parse error, parse error, Parse error: A 'concrete' solution available? nothingman Questions and Comments 6 06-06-2008 02:28 AM
Parse error: parse error, unexpected $ bbrian017 Questions and Comments 7 04-09-2008 10:38 AM
HELP: Continuos parse errors when trying to change the template code juanmartinbravo Questions and Comments 7 01-26-2008 06:03 AM
How would this error be caused? Parse error: parse error bbrian017 Questions and Comments 0 12-10-2007 11:04 AM
Got This Parse Error on c_ file on line 141 endph Questions and Comments 0 02-14-2007 07:44 PM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development