Page 1 of 1

Error with Smarty in Plugin Comment

Posted: Sat Feb 19, 2005 2:26 pm
by thomsen
Hi , i wantet to use the comment pluging.
I createt a new content section with the plugin tag and everything works untill the users press the submit button.
The comment is written into Mysql ( and shown on next view of the comment-side ) but this message apears :

Warning: Smarty error: unable to read resource: "db:7?CMSSESSID=7efdf4ad7331919a18dafce41f48c1b6" in /raid/domains/de/p/philter-music/htdocs/www/lib/smarty/Smarty.class.php on line 1088

Anybody got an idea ?

Error with Smarty in Plugin Comment

Posted: Sat Feb 19, 2005 2:39 pm
by Robin
I have a similar problem, whenever I add a comment I get this error:
Warning: Smarty error: unable to read resource: "db:6?CMSSESSID=f71ac381f17cd27dc316ffbfb5bf5205" in /home/robin/public_html/cms/lib/smarty/Smarty.class.php on line 1088
But then I can see the comment after it's added, so I'm not sure what the problem is. By the way, line 1088 is:
trigger_error("Smarty error: $error_msg", $error_type);
But that's probably not of much use.

Error with Smarty in Plugin Comment

Posted: Sat Feb 19, 2005 2:45 pm
by thomsen
i think line 1088 ist just the function which return the errors smarty had ...

Error with Smarty in Plugin Comment

Posted: Sat Feb 19, 2005 2:54 pm
by Robin
thomsen wrote:i think line 1088 ist just the function which return the errors smarty had ...
Yeah that's what I figure, but I had too much time on my hands.

Error with Smarty in Plugin Comment

Posted: Mon Feb 21, 2005 5:13 pm
by Robin
:bump:

Any answers??

Error with Smarty in Plugin Comment

Posted: Mon Feb 21, 2005 5:38 pm
by Ted
I just tested it locally, and it works fine. Anyone else?

Error with Smarty in Plugin Comment

Posted: Mon Feb 21, 2005 6:42 pm
by Robin
I'm using PHP version 4.3.10, maybe that makes a difference??

Error with Smarty in Plugin Comment

Posted: Mon Feb 21, 2005 6:49 pm
by Ted
Me too

dirty workaround

Posted: Tue Feb 22, 2005 11:05 am
by Thomsen
Here is a dirty, but working "solution" for this prob.:

Open file /modules/Comments/modulefunctions.php

Line 100: cms_mapi_redirect_user_by_pageid($return_id);
replace with echo "ok, if you dont like to"; or something like this.

Line 141 : cms_mapi_redirect_user_by_pageid($return_id);
replace with echo "thanx for your entry"; or something like this.

Thomas

Re: Error with Smarty in Plugin Comment

Posted: Wed Apr 13, 2005 8:20 pm
by matt
OK, so the reason here seems to be that the URL to which execution is redirected has the CMSSESSID given with '?' to separate attributes. Like this:
http://www.yourdomain.com/index.php?pag ... 191f6c00cc

and some newer PHP versions seem to have solved this problem.

It woud help if there was no CMSSESSID set (no attributes), like this:
http://www.yourdomain.com/index.php?page=Forum

or if '&' was used as a separator instead of '?', like this:
http://www.yourdomain.com/index.php?pag ... 191f6c00cc

One can do both and it was described here how to do it:
http://forum.cmsmadesimple.org/index.ph ... 620.0.html

But I don't have access to my php.ini and setting it in .htaccess doesn't work. Any ideas how to set any of these other way?