Page 1 of 1

Fatal error - Smarty error [Solved]

Posted: Sat Mar 04, 2006 1:58 pm
by monolegis
Hello, Thanks for a nice cms!

I got an error message after editing a page, and I got no clue to what it means. Anyone got a clue?

I have done nothing other than editing an existing page, so why did I suddenly get an error message when I try to wiev it?

Fatal error: Smarty error: [in content:content_en line 3]: syntax error: unrecognized tag: size: 21cm 29.7cm; margin: 2cm (Smarty_Compiler.class.php, line 436) in /public_html/mandriva/lib/smarty/Smarty.class.php on line 1088

I am using:
cmsmadesimple-0.11.2
Apache 1.3.34
MySQL 4.1.18

___________________________________________________________

It looks like pasting from open office adds som code you don't see unless you use the "source code".

Code: Select all

<meta http-equiv="CONTENT-TYPE" content="text/html; charset=utf-8" />
<title></title>
<meta name="GENERATOR" content="OpenOffice.org 1.1.5  (Linux)" />
<meta name="CREATED" content="20060304;12584900" />
<meta name="CHANGED" content="20060304;13001400" /> 	 	 	 	 	<style type="text/css">
	<!--
		@page { size: 21cm 29.7cm; margin: 2cm }
		P { margin-bottom: 0.21cm }
	-->
	</style>  </p>

Re: Fatal error - Smarty error

Posted: Sat Mar 04, 2006 2:22 pm
by cyberman
monolegis wrote: I have done nothing other than editing an existing page, so why did I suddenly get an error message when I try to wiev it?
What have you insert in the existing page? It looks you've used inadvertently a smarty tag  ::) or so other cause CMSms missunderstood this ...

Re: Fatal error - Smarty error

Posted: Sat Mar 04, 2006 2:25 pm
by monolegis
Only plain text, and hyperlinks. I have pasted som text from openoffice, but this text was deleted. The page worked fine before i started pasting in from openoffice.  And what is a smarty tag?

Re: Fatal error - Smarty error

Posted: Sat Mar 04, 2006 2:32 pm
by monolegis
Aaah sorry for this post, I removed all text, and now it works. still annoying that I couldn't find the cause of the error. Anyway, thanks for the reply.

[Edit] Wishy was right.

The problem is that it inserted css into the page.  Whenever there is a block of css or javascript (anything with a { or }), it has to be wrapped in {literal}{/literal} tags, because the smarty processor gets confused.

[/edit]

Re: Fatal error - Smarty error

Posted: Sat Mar 04, 2006 2:38 pm
by Ted
The problem is that it inserted css into the page.  Whenever there is a block of css or javascript (anything with a { or }), it has to be wrapped in {literal}{/literal} tags, because the smarty processor gets confused.