Hey all,
I had setup a cron job to change some incentives of mine at different times during the day. I’m noticing though that sometimes it doesn’t actually change the prices on the homepage, and that to make it change I manually have to put ?cc in the admin area.
Is there some way around this? Or a way to keep CS Cart from maintaining template cache??
You don’t want to disable template caching. However, if you’re updating the database through some custom function, you might have to remove the var/cache directory (which is the Registry). Many DB queries for things like product info are cached in the registry.
When you say in the Registry, I’m not seeing any directory called that… am I assuming correctly just the directory of var/cache/ itself? Or can I possibly remove one of the directories inside the cache directory to keep it from maintaining that?
I was thinking of just renaming it instead. Would that cause any problems?
He didn’t say IN the registry, he said the var/cache directory IS the registry
I would not try to outsmart the registry by removing selected files. While there is a possibility to do so, I would not recommend it. You should either remive the var/cache directory and its contents or remove the contents. Removing the whole directory is preferred cuz it will be recrated when it is needed.
I attempted to delete the registry, but when it rebuilds itself, we seem to have the same problem. Did you mean to suggest that I should add the function to delete the registry into the custom db changing function each time it runs? Or do you think that would work if that wasn’t your original thought?
[quote name=‘tbirnseth’]I would not try to outsmart the registry by removing selected files. While there is a possibility to do so, I would not recommend it. You should either remive the var/cache directory and its contents or remove the contents. Removing the whole directory is preferred cuz it will be recrated when it is needed.[/QUOTE]
Hello,
How do I set up a cron job to remove the cache during the day?
Thank you in avdance.
Tom
If you’re modifying the DB outside the application, you should always clear the registry cache. Not sure why you want to keep clearing the cache. If you have an issue that is requiring that, clearing the cache is not the solution, it is rectifying a symptom.
[quote name=‘LarryU’]Hey all,
I had setup a cron job to change some incentives of mine at different times during the day. I’m noticing though that sometimes it doesn’t actually change the prices on the homepage, and that to make it change I manually have to put ?cc in the admin area.
Is there some way around this? Or a way to keep CS Cart from maintaining template cache??[/QUOTE]
Which command did you put at cron job list?
When you do it manually ( I mean yourdomain/admin.php?cc ) is it Working?