Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Theme caching plugin  (Read 9136 times)

0 Members and 1 Guest are viewing this topic.

ron4mac

  • Administrator
  • Coppermine addict
  • *****
  • Country: us
  • Offline Offline
  • Posts: 2026
Theme caching plugin
« on: July 07, 2020, 02:22:07 pm »

Here is a CPG 1.6.x plugin that will cache home, category and album pages for non logged in users. Set cache expiration time in plugin config. Themes must be enabled for caching by creating a writeable "cache" folder in the theme folder.

The plugin should greatly reduce database accesses and increase performance for public facing galleries.

Updated: V1.0 adds a <!-- CACHED --> tag to the bottom of the page when delivered from cache (for support purposes).

« Last Edit: March 07, 2021, 02:23:08 pm by ron4mac »
Logged

idosha

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 27
Re: Theme caching plugin
« Reply #1 on: July 30, 2020, 03:35:56 am »

Thank you very much for this plugin. It has helped me greatly reduce my server load.

Question, what will happen if the "cache" folder doesn't exist? Is the plugin just ignored then?

Is there no way to make the "cache" folder inside the plugin folder or a "temp" folder? I see it being a nuisance to have to remember to create a "cache" folder when activating new themes.
Logged

giovane234

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: Theme caching plugin
« Reply #2 on: August 12, 2022, 04:30:44 am »

Hey, ron4mac! First of all, thank you very much for this plugin!

Do you know if it still works in CPG 1.6.19? I installed it, but apparently it is not generating the cache :(
Logged

ron4mac

  • Administrator
  • Coppermine addict
  • *****
  • Country: us
  • Offline Offline
  • Posts: 2026
Re: Theme caching plugin
« Reply #3 on: August 12, 2022, 01:06:30 pm »

Yes, it should function okay with CPG 1.6.19. Three things have to be true for the cache to happen: the plugin must be installed and enabled, the theme folder must have a web-server writable 'cache' folder and the gallery must be accessed by a guest user (not logged in). Caching can not happen for logged in users.
Logged

giovane234

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: Theme caching plugin
« Reply #4 on: January 14, 2023, 11:57:14 pm »

Hi ron4mac, thanks for the answer!

I followed all the steps and the plugin didn't work properly. The generated cache pages only render up to the breadcrumb. Any idea what could be the reason?

My gallery is big and has almost 300,000 pictures. It would be extremely interesting for me to be able to activate this plugin. My home page, for example, is taking about 30 seconds to load...
Logged
Pages: [1]   Go Up
 

Page created in 0.022 seconds with 20 queries.