Forums / Developer / template overrides not working for translations
Cristina Carvalho
Thursday 28 April 2011 3:11:27 pm
Hello,
I'm a developer working on a ez publish website previously created by another developer. I'm relatively new to EZ Publish but I found my way around overriding templates, creating new classes, translating content.
However, the new template overrides seem to only work in the default site language. When I click the English or Spanish version it does not fetch the same template overrides and uses the old overrides instead.
How can I fix this? :( Thank you in advance for your help..!
Greg McAvoy-Jensen
Friday 29 April 2011 12:01:30 am
Cristina,
Are the override rules for the new templates in the siteaccess for the default site language? Be sure they are accessible for the English and Spanish siteaccesses as well. And of course clear the cache.
Granite Horizon, Certified Developer of eZ Publish Web Solutions Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg Blog: http://granitehorizon.com/blog
Saturday 30 April 2011 4:36:34 am
Christina,
Oh, I didn't know there were siteaccess rules for each language, I shall look for those files then.
I've heard a lot about clearing cache, which is the best way? Should I just delete those files that end with a "~" ?
I apologize in advance if my questions are so basic, but I wasn't the developer behind the system and there were many concepts I only grasped at a glimpse...
Thank you in advance for your kind response!
Saturday 30 April 2011 8:29:29 am
You can clear the cache by:
In practice, using the first option should take care of it. Note that if you're in a production environment on a server that's getting hit hard, clearing all caches is risky, because the work of generating all caches at once may be too much for the server. In this case clear caches of only the page you need (in admin, navigate to the object and click the icon next to its name; then delete view cache). or the type you need (ini cache, template block cache, etc.
Sunday 01 May 2011 3:46:58 am
Thank you very much Greg! You were a great help! :)