Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

magento appends a querystring parameter to CSS and JS

How Can I appends a querystring parameter to each CSS and JavaScript include in the HTML to clear CSS and JavaScript cache. I have tried

<action method="addCss"><stylesheet>css/style.css?123</stylesheet></action>

and

<action method="addItem"><type>skin_css</type><name>css/styles.css?123</name><params/></action>

. But each time it returns a the base package like

http://www.example.com/skin/frontend/base/default/styles.css?123

not my custom theme directory .

How to solve this ?

like image 806
zhipeng Avatar asked Jul 06 '12 06:07

zhipeng


1 Answers

This free extension should do what you want - works perfectly for me:

https://github.com/jreinke/magento-suffix-static-files

like image 57
gregdev Avatar answered Sep 20 '22 16:09

gregdev