Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Smarty 2.6.18, PHP 5.3.14 and Undefined variable

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Installation and Setup
View previous topic :: View next topic  
Author Message
barat
Smarty n00b


Joined: 11 Jul 2012
Posts: 2

PostPosted: Wed Jul 11, 2012 9:59 am    Post subject: Smarty 2.6.18, PHP 5.3.14 and Undefined variable Reply with quote

Hello,

I have a problem with smarty.

I moved from one server which was PHP 5.2.17 to a new one where PHP is 5.3.14.

From now I have a problem - page is almost not displaying and in apache error log i have lot of:
Quote:
Undefined variable: XXX in /home/admin/domains/XXX/public_html/index.php on line XX

The funniest thing is that those vars are set - everything works on the old server.

Do I need to downgrade PHP to 5.2, or there is some other sollution?

Can someone help me?

I'm not using smarty at all - all new projects are on Kohana 3 without using template systems. This one is Old, it was "in my company" before I came, and in future will be re-writen, but now I have to make it work again.


EDIT:
It seems to work now ... i just downgraded PHP to 5.2.17 on the server ... I hope that this will be premanent fix.
Back to top
View user's profile Send private message
mohrt
Administrator


Joined: 16 Apr 2003
Posts: 7368
Location: Lincoln Nebraska, USA

PostPosted: Wed Jul 11, 2012 1:46 pm    Post subject: Reply with quote

Is the variable on that page undefined? On your newer PHP version you could have had your error reporting set differently to show all notices.
Back to top
View user's profile Send private message Visit poster's website
barat
Smarty n00b


Joined: 11 Jul 2012
Posts: 2

PostPosted: Thu Jul 12, 2012 1:34 pm    Post subject: Reply with quote

It's not that.
i changed error display method in php.ini to ignore Deprecated and Notice.

It's just something with passing with reference in PHP5.2 and PHP5.3 I think.
Back to top
View user's profile Send private message
mohrt
Administrator


Joined: 16 Apr 2003
Posts: 7368
Location: Lincoln Nebraska, USA

PostPosted: Thu Jul 12, 2012 1:49 pm    Post subject: Reply with quote

Is the error coming from a template? Maybe this will help:

http://www.smarty.net/docs/en/api.mute.expected.errors.tpl

Also see:

http://blog.rodneyrehm.de/archives/12-Improving-Disk-IO-in-PHP-Apps.html
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Installation and Setup All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP