|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
tanila Smarty n00b
Joined: 03 Mar 2012 Posts: 4
|
Posted: Sat Mar 03, 2012 10:26 am Post subject: upgrade from 3.0.8 to 3.1.8 |
|
|
Hello,
I am using Smarty for 4-5 jears now in my cusom CMS. I upgrades form Smarty 3.0.8 to 3.1.8 now ma Problem:
I stored a smarty-instance in an Object which is stored in the session. On a new created session there is no Problem. The page is displayed. But if a session is established I get the following exception:
Uncaught exception 'SmartyException' with message 'Invalid compiled template for: 'PATHTOTEMPLATE/TEMPLATE.tpl'
The smarty testfunction showed no Problems. All Paths are set correctly. I did not enable smarty-caching.
Are there some changes made in 3.1.8 relational to sessions in Smarty?
Can someone point me to a direction? |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Sat Mar 03, 2012 11:51 am Post subject: |
|
|
Did you delete all old existing compiled template files after upgrading?
Because of internal changes the compiled files are not combatible. |
|
Back to top |
|
tanila Smarty n00b
Joined: 03 Mar 2012 Posts: 4
|
Posted: Sat Mar 03, 2012 12:09 pm Post subject: |
|
|
Hi U.Tews,
shure I deleted the smarty-compile-dir
Smarty created a new compiled template, so that worked.
On the current testing-site I am using just one template, so there was only one file to delete.
I think this is a session problem, because of the strange behaviour described in my 1st post (new session -> it worked and with existing session -> the Error). |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Sat Mar 03, 2012 2:32 pm Post subject: |
|
|
Storing the Smarty instance in a session can't really work as for example Smarty 3 does cache internal data in static varibales which get lost.
It seem to be just luck that it did work in your case with 3.0 |
|
Back to top |
|
tanila Smarty n00b
Joined: 03 Mar 2012 Posts: 4
|
Posted: Sat Mar 03, 2012 3:14 pm Post subject: |
|
|
Oh no...
Is there a way to disable smarty's internal caching? |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Sat Mar 03, 2012 3:43 pm Post subject: |
|
|
No way. Smarty was never writen to support this. |
|
Back to top |
|
tanila Smarty n00b
Joined: 03 Mar 2012 Posts: 4
|
Posted: Sat Mar 03, 2012 4:14 pm Post subject: |
|
|
ok thank you |
|
Back to top |
|
|
|
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
|