Page 1 of 1

[SOLVED] Help solving an intermittent Smarty error on first load

Posted: Thu Jun 24, 2010 2:44 pm
by luminous
Quite often the first time I load my site in Firefox I get the following showing at the top of my screen:
string(126) "Smarty error: [in tpl_body:24 line 166]: syntax error: '=' cannot be an attribute value (Smarty_Compiler.class.php, line 1583)"
Then, when I reload the site it goes away.  However, later on it will come back again.

I do not know why it is intermittent , nor do I know how to diagnose it either :(
I have previously caused some errors,  but it was immediately after doing something which made it a lot easier to go and find where the issue was.

I do not have a template called tpl_body, and I do not have any smarty code at line 166 that I can see, and non of my templates go up to line 1583.  I presume this is happening as several things are all being processed, but narrowing it down is proving a little difficult....
Running CMSMS 1.71 on Xampp 1.7.3 on Win 7
----------------------------------------------

Cms Version: 1.7.1

Installed Modules:

   * CMSMailer: 2.0
   * FileManager: 1.0.2
   * MenuManager: 1.6.3
   * ModuleManager: 1.3.3
   * News: 2.10.5
   * nuSOAP: 1.0.1
   * Printing: 1.0.4
   * Search: 1.6.3
   * ThemeManager: 1.1.1
   * TinyMCE: 2.7.0
   * TemplateExternalizer: 1.2
   * Gallery: 1.3
   * FormBuilder: 0.6.2
   * SelfRegistration: 1.4.2
   * CGExtensions: 1.18.8
   * CGSimpleSmarty: 1.4.4
   * Products: 2.8.2
   * CGEcommerceBase: 1.1.1
   * Cart: 1.6.2
   * FrontEndUsers: 1.9.3
   * CGPaymentGatewayBase: 1.0.5
   * Orders: 1.8.6
   * PaypalGateway: 2.1.7


Config Information:

   * php_memory_limit:
   * process_whole_template: false
   * max_upload_size: 128000000
   * default_upload_permission: 664
   * assume_mod_rewrite: true
   * page_extension:
   * internal_pretty_urls: false
   * use_hierarchy: true


Php Information:

   * phpversion: 5.3.1
   * md5_function: On (True)
   * gd_version: 2
   * tempnam_function: On (True)
   * magic_quotes_runtime: Off (False)
   * E_STRICT: 0
   * E_DEPRECATED: 0
   * memory_limit: 128M
   * max_execution_time: 60
   * safe_mode: Off (False)
   * session_save_path: C:\xampp\tmp (0777)
   * session_use_cookies: On (True)


Server Information:

   * Server Api: apache2handler
   * Server Db Type: MySQL (mysql)
   * Server Db Version: 5.1.41


----------------------------------------------

Re: Help solving an intermittent Smarty error on first load

Posted: Thu Jun 24, 2010 2:46 pm
by calguy1000
line 166 of the portion of your page template.

Re: Help solving an intermittent Smarty error on first load

Posted: Thu Jun 24, 2010 2:59 pm
by luminous
Thanks calguy.  I went into the main template in CMSMS (not the generated page source), and copied that into Notepad++.  Then I found the body section and copied that into a new text document so I could see where line 166 actually was.

I found some smarty code the line above, and it looks it may be wrong so I have changed that, so far the error is not present.

Thanks again :)