Parse error: syntax error, unexpected

Register an Account
Pligg Chat Room
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-04-2009, 04:27 AM
New Pligger
Pligg Version: 1.0
 
Join Date: Mar 2009
Posts: 13
Hi all,

Tried to make a more beautiful header and took away this code in templates/wistie/header.tpl:

<div id="logo"><a href="{$my_base_url}{$my_pligg_base}">{#PLIGG_Visu al_Name#}</a></div>

After that:

Parse error: syntax error, unexpected '{' in /yoursite/class.template.php(745) : eval()'d code on line 62

Copied

<div id="logo"><a href="{$my_base_url}{$my_pligg_base}">{#PLIGG_Visu al_Name#}</a></div>

back to templates/wistie/header.ptl.

Now I receive

Parse error: syntax error, unexpected '{' in /yoursite/cache/templates_c/c_6554aa420b023928ce6a0352e4766261.php on line 62

and after deleting cache still

Parse error: syntax error, unexpected '{' in /yoursite/class.template.php(745) : eval()'d code on line 62

Please help. Thanks.
Reply With Quote
  #2 (permalink)  
Old 04-04-2009, 04:41 AM
New Pligger
Pligg Version: 1.0
 
Join Date: Mar 2009
Posts: 13
Overwrote header.tpl with the same file from the installation package.

Now it works again and I will not play around alone anymore ;-)
Reply With Quote
  #3 (permalink)  
Old 06-22-2009, 06:10 PM
New Pligger
Pligg Version: 1.0.0
 
Join Date: Jun 2009
Posts: 1
I had the same error and corrected by the same method but how can I add a logo in this case?
Reply With Quote
  #4 (permalink)  
Old 06-27-2009, 12:12 PM
Casual Pligger
Pligg Version: 1.0.0
Pligg Template: wistie
 
Join Date: Jun 2009
Location: Greece
Posts: 58
i had the same error after trying to put a 728X60 banner on top - thanks for the advice, really helped because i freak out with error messages....
Reply With Quote
  #5 (permalink)  
Old 07-02-2009, 03:22 PM
New Pligger
 
Join Date: Jul 2009
Posts: 7
and... where is the solution? how comes that no one knows how to change the header? does the developers know this issue?
Reply With Quote
  #6 (permalink)  
Old 07-02-2009, 07:09 PM
MissDanni's Avatar
Casual Pligger
Pligg Version: 1.0.2
Pligg Template: mystique
 
Join Date: Jun 2009
Posts: 70
The admin template editor seems to always give me errors too.

My Solution:
Copy the header file to your PC.
Make a backup of this file in case you mess up.
Add your changes to the header.
Upload back to your server replacing the existing header.

-Use at own risk-
Reply With Quote
  #7 (permalink)  
Old 07-10-2009, 10:04 PM
New Pligger
 
Join Date: Jul 2009
Posts: 1
This is how I fixed the problem. Go to Templates in the admin menu, open header.tpl and find the following lines:

{php}
global $URLMethod, $my_base_url, $my_pligg_base;
if ($URLMethod==2)
print "onsubmit='document.location.href="{$my_base_url}{ $my_pligg_base}/search/"+encodeURIComponent(this.search.value); return false;'";
{/php}

Replace them with these:

{php}
global $URLMethod, $my_base_url, $my_pligg_base;
{/php}
{if $URLMethod eq 2}
onsubmit='document.location.href="{$my_base_url}{$ my_pligg_base}/search/"+encodeURIComponent(this.search.value); return false;'
{/if}

Save this template and refresh your site in the browser.
Reply With Quote
Reply

Tags
cache, parse error, syntax

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 01:28 AM
Parse error: parse error, unexpected $ bbrian017 Questions and Comments 7 04-09-2008 09:38 AM
HELP: Continuos parse errors when trying to change the template code juanmartinbravo Questions and Comments 7 01-26-2008 05:03 AM
Parse error: parse error, unexpected $, expecting ')' LeoNel Questions and Comments 19 10-29-2007 09:12 PM
Got This Parse Error on c_ file on line 141 endph Questions and Comments 0 02-14-2007 06: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