I currently am using zencart version 1.37 and am not caching my SQL file.
I would like to change the SQL cache to cache to file.
What files do I need to edit and what edits do I need to do to the files inorder to cache to file?
Thanks,
Adam Fontana
I currently am using zencart version 1.37 and am not caching my SQL file.
I would like to change the SQL cache to cache to file.
What files do I need to edit and what edits do I need to do to the files inorder to cache to file?
Thanks,
Adam Fontana
There are 3 caching options:
1. None
2. Cache to File
In your /includes/configure.php and /admin/includes/configure.php files, you'll see this section, which explains the requirements:
3. Cache to DatabaseCode:// The next 2 "defines" are for SQL cache support. // For SQL_CACHE_METHOD, you can select from: none, database, or file // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder // ie: /path/to/your/webspace/public_html/zen/cache -- leave no trailing slash define('SQL_CACHE_METHOD', 'file'); define('DIR_FS_SQL_CACHE', '/enter/your/path/to/public_html_or_htdocs/and/zencart/here/zen/cache');
Caching to database can be enabled simply by setting SQL_CACHE_METHOD to 'database' ... in both configure.php files as mentioned in #2 above.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
What are the advantages and disadvantages of files Vs database?![]()
Well, I started with 'file' and that made a major improvement!![]()
With the browser cache cleared, the homepage parse time reduced from 19 seconds to around 3. Actually, I'm surprised this isn't the default setting?
Gonna stick with 'file' unless there's a reason not to.
Next stop... Gzip.