-
AuthorPosts
-
May 24, 2012 at 12:10 pm #177492
Hi all,
I have a problem with de browser cache (in Ja-Kranos Jl 1.5). In Joomla you can adjust the parameter for the server cache and also for the browser cache. But if you take out the browser cache and you change your template.css, you will have to press Ctrl+F5 to see the style changes. I have read in other forums that this is because of the browser cache and I have to cheat the browser changing the css calls in the index in the <head>. This should be an easy task, but I haven’t found the place where are the css calls in the Kranos template.
In conclusion: I need that when a user that have the css sheets saved in his browser cache enter in my website, doesn’t need to press Ctrl+F5 to see the changes.
Thanks
Best Regards
Wall Crasher DeveloperWall Crasher
- Join date:
- December 2011
- Posts:
- 1113
- Downloads:
- 0
- Uploads:
- 15
- Thanks:
- 66
- Thanked:
- 361 times in 300 posts
May 25, 2012 at 9:23 am #454868Hi sigmaaie
You could cusotmize 2 code block in plugins/system/jat3/jat3/core/head.php
//re-add stylesheet to head
foreach ($css_urls as $urls) {
foreach ($urls as $url) {
if (count($url) > 2) {
$attrs = $url[2];
$document->addStylesheet($url[1], $attrs['mime'], $attrs['media'], $attrs['attribs']);
} else {
$document->addStylesheet($url[1]);
}
}
}
and
//re-add stylesheet to head
foreach ($scrips as $url) {
$document->addScript($url[1]);
}
1 user says Thank You to Wall Crasher for this useful post
May 29, 2012 at 1:10 pm #455370Thank you Do Ha,
Our knowledge of php is nothing, but the thing that we did was to put this line of code
( $document->addStyleSheet( ‘/templates/’ . $document->template . ‘/local/themes/css/new_css.css’ ); )
at the end of the ” function proccess() ” in head.php.
But the problem is that everytime we want to change css we need to change the name of the css file and this line in head.php. There is any automatic way of doing this?
Thank you very much!!
Ninja Lead ModeratorNinja Lead
- Join date:
- November 2014
- Posts:
- 16064
- Downloads:
- 310
- Uploads:
- 2864
- Thanks:
- 341
- Thanked:
- 3854 times in 3563 posts
June 6, 2012 at 1:19 pm #456306Thank You Ninja Lead, is a good option!
June 14, 2012 at 4:18 am #457326Hi! sorry i have the same problem, every time i make a change in the content of my site, in particularly pictures, no body notes the
changes until they refresh the browser cache. I kind a dummy 😛 i didn’t understand correctly the other posts , which lines of code
should i change in the head.php and which CSS should i add??Many thanks!
Ninja Lead ModeratorNinja Lead
- Join date:
- November 2014
- Posts:
- 16064
- Downloads:
- 310
- Uploads:
- 2864
- Thanks:
- 341
- Thanked:
- 3854 times in 3563 posts
June 15, 2012 at 4:23 am #457488<em>@juanalverto 325277 wrote:</em><blockquote>Hi! sorry i have the same problem, every time i make a change in the content of my site, in particularly pictures, no body notes the
changes until they refresh the browser cache. I kind a dummy 😛 i didn’t understand correctly the other posts , which lines of code
should i change in the head.php and which CSS should i add??Many thanks!</blockquote>
Because your site is using many cache on the page: template cache, module cache, compress css and js….. you can disable cache by:
Template cache : Go to admin->Extensions->Template Manager->Your template->Edit->Enable Development Mode(NO), Enable Template Information(No)
Module cache : Go to admin->Extensions->Module Manager->Edit Item Module -> Advanced Options tab ->Caching(No caching)
1 user says Thank You to Ninja Lead for this useful post
-
AuthorPosts
This topic contains 7 replies, has 4 voices, and was last updated by Ninja Lead 12 years, 5 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum