Module template cache

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
User avatar
dam
Forum Members
Forum Members
Posts: 136
Joined: Sat Jan 14, 2006 6:07 pm

Module template cache

Post by dam »

Hello,

I'm developping module Album which introduces a new content type to display photo albums.
My question is : how is it possible to manage template cache with modules ?

If I indicates that the content is cached, it will not take into account further modifications in albums (the page is not modified when we modify the content of an album).

I saw that there is a function in module API called "IsDatabaseTemplateCached". Is anyone able to document this function, or indicate an example of use of this function ?

Thanks in advance,
Dam
mikemcvey
Forum Members
Forum Members
Posts: 61
Joined: Tue May 02, 2006 4:08 am

Re: Module template cache

Post by mikemcvey »

something I want to know as well!

Good luck
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am

Re: Module template cache

Post by Elijah Lofgren »

It looks like the smarty template cache was disabled 8 days ago.  :D
See: http://viewsvn.cmsmadesimple.org/viewsv ... 2&view=log
That means once 0.13 beta 2 comes out (pretty soon from what I hear) we'll no longer have to worry about Smarty caching our pages.  :)
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
User avatar
dam
Forum Members
Forum Members
Posts: 136
Joined: Sat Jan 14, 2006 6:07 pm

Re: Module template cache

Post by dam »

Elijah Lofgren wrote: It looks like the smarty template cache was disabled 8 days ago.  :D
See: http://viewsvn.cmsmadesimple.org/viewsv ... 2&view=log
That means once 0.13 beta 2 comes out (pretty soon from what I hear) we'll no longer have to worry about Smarty caching our pages.  :)
Well  :-\
What will be the impact on site speed ?
cyberman

Re: Module template cache

Post by cyberman »

It will be faster  :D ...
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Module template cache

Post by Ted »

Surprisingly, it's faster.  Because we're grabbing templates from the database and compiling them first (and only do it if the timestamp has changed), that acts as a cache in itself.  Then, if you have smarty cache the output as well, it becomes this doubled sort of mess.  All the testing I've done has shown that it's faster without the smarty caching on and just using the compiled templates as the cache instead.

I guess we'll see what happens when beta2 comes out tonight.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Module template cache

Post by Dr.CSS »

? Tonite ? oh boy i can't wait,

    mark
User avatar
dam
Forum Members
Forum Members
Posts: 136
Joined: Sat Jan 14, 2006 6:07 pm

Re: Module template cache

Post by dam »

If I understand well, it is not necessary for me to look at speed concern in my module for templates : CMSMS does it for me ?
Cool  8)
Post Reply

Return to “Developers Discussion”