Fooman Speedster
Please note that this extension is provided as is. It is recommended to always backup your installation prior to usage.
| Created | |
| Last Updated | Mon, June 8, 2009 |
| Version | 1.0.4 |
| Compatibility | Magento 1.2-1.3 |
| Stability | stable |
| Locales available in this package | N/A |
| Downloads | 13644 |
| Community Rating | |
| Categories | Other |
| License Type | Open Software License (OSL) |
| Tags | speed, smaller, Minify, FOOMAN, faster |
Overview
Speed up your store by combining, compressing and caching JS and CSS.
Speed up your store by combining, compressing and caching JS and CSS. This extension reworks how Magento handles the loading of JavaScript and CSS. It utilises the Minify library developed by Steve Clay and released under a BSD license.
See the attached screen shots for a before / after comparison on my setup.
* Javascript AND CSS are combined into one file each
* compression even without gzip support on your server
* Automatic Versioning - every time you update one of your JS/CSS files a new url gets created forcing the customer's browser to request the new version (be sure to update the Magento cache as well)
* Minify does its magic to ensure that CSS images are properly served no matter what package/interface/skin you are using.
* needs mod_rewrite enabled / .htaccess support
* some JS and CSS are currently excluded (for example print.css)
* Installation of CANONICAL URLs by Yoast breaks this extension. A work-around is posted here.
* Installation of MXPERTS JQUERY BASE breaks this extension. Tips are posted here.
1. ) Add the following to your .htaccess
############################################
## Compress, Combine and Cache Javascript/CSS
RewriteRule ^(index.php/)?minify/([^/]+)(/.*.(js|css))$ lib/minify/m.php?f=$3&d=$2
Directly underneath the Rewrite Base Rule and the workaround for HTTP authorization rule. Advanced: For installation on a non-Standard Linux installation check out the ISAPI2 and Nginx threads.
2.) In the same htaccess uncomment the RewriteBase rule and make sure it points to the folder where Magento's main index.php resides in.
3.) After installing this extension via Magento Connect make sure that /lib/minify/m.php is executable (permissions like 755 on the file itself and the containing folder should work) and /var/minifycache is writeable.
4.) Minifying JS and CSS takes a while to compute (~20seconds on my machine). This only needs to be done once per JS/CSS combination and is then written to a cache. To make sure the cache gets filled up simply browse your store and your customers should have a faster experience than before.
If you are running a multi store set up please follow these instructions . Additionally add a symlink to the lib folder.
Please note the above instructions apply to FOOMAN_Speedster 0.7.0 and above and are slightly different to previous versions.
For users of versions 0.7.0 - 0.7.6 please note that editing /app/design/frontend/YOURINTERFACE/YOURTHEME/layout/page.xml is not needed any more. Please change it back to the original validation.js instead of validation-4min.js
Please review all the steps listed in this thread. It has the most common errors with solutions listed - when posting any questions please include the output of the 4 steps listed.
Don't disable the output of Fooman_Speedster under Configuration > Advanced - it will make your site unusable. To uninstall either use Magento Connect or edit /app/etc/modules/Fooman_Speedster.xml (change true to false).
Additional support can be obtained through our website.
1.0.4 Updated bundled validation.js to newer build, minor fixes
1.0.2 Updated to newer minify build
1.0.0 First Stable Release
0.9.4 RC1 (updated to minify 2.1.2, added support for minifying skin_js) - simplified .htaccess rewriteRule (thanks to PremierWeb)
0.9.3 reversed adding subdirectory to paths
0.9.2 change in detection of subdirectory
0.9.1 correct timestamps for subdirectory installs
0.9.0 fixed bug in handling of subdirectories - .htaccess has been UPDATED!
0.8.2 removed check for Core dependency
0.8.1 automatically configure paths for multi stores
0.8.0 multi store functionality now supported - please read the documentation forum for details
0.7.16 updated to work with Magento 1.2 - form_key support, thanks jemoon
0.7.15 fixed multiple sites date stamp issue
0.7.14 reworked paths - should enhance cross-platform support
0.7.10 admin areas now supported, reworked folder handling - .htaccess HAS CHANGED!
0.7.9 set docroot for IIS - could solve image handling bug
0.7.8 fixed bug introduced with 0.7.7 - automatic handing of validiation-4min.js
0.7.7 updating to Minify 2.1.1 (support for symlinks)
0.7.6 load CSS before JS - this should allow the browser to render the page earlier
0.7.5 fixed bug introduced with 0.7.4 (load JS/CSS securely when needed)
0.7.4 non-webroot installations now handled properly (.htaccess needs to be changed accordingly)
0.7.3 handle js_css files
0.7.2 fixed bug with index.php
0.7.1 added .htaccess to /lib/minify folder to allow access
0.7.0 now with automatic versioning support, automatic configuration of used skin and proper Magento field validation
See the attached screen shots for a before / after comparison on my setup.
Benefits
* Javascript AND CSS are combined into one file each
* compression even without gzip support on your server
* Automatic Versioning - every time you update one of your JS/CSS files a new url gets created forcing the customer's browser to request the new version (be sure to update the Magento cache as well)
* Minify does its magic to ensure that CSS images are properly served no matter what package/interface/skin you are using.
Current Requirements / Caveats
* needs mod_rewrite enabled / .htaccess support
* some JS and CSS are currently excluded (for example print.css)
* Installation of CANONICAL URLs by Yoast breaks this extension. A work-around is posted here.
* Installation of MXPERTS JQUERY BASE breaks this extension. Tips are posted here.
Installation
1. ) Add the following to your .htaccess
############################################
## Compress, Combine and Cache Javascript/CSS
RewriteRule ^(index.php/)?minify/([^/]+)(/.*.(js|css))$ lib/minify/m.php?f=$3&d=$2
Directly underneath the Rewrite Base Rule and the workaround for HTTP authorization rule. Advanced: For installation on a non-Standard Linux installation check out the ISAPI2 and Nginx threads.
2.) In the same htaccess uncomment the RewriteBase rule and make sure it points to the folder where Magento's main index.php resides in.
3.) After installing this extension via Magento Connect make sure that /lib/minify/m.php is executable (permissions like 755 on the file itself and the containing folder should work) and /var/minifycache is writeable.
4.) Minifying JS and CSS takes a while to compute (~20seconds on my machine). This only needs to be done once per JS/CSS combination and is then written to a cache. To make sure the cache gets filled up simply browse your store and your customers should have a faster experience than before.
If you are running a multi store set up please follow these instructions . Additionally add a symlink to the lib folder.
Please note the above instructions apply to FOOMAN_Speedster 0.7.0 and above and are slightly different to previous versions.
For users of versions 0.7.0 - 0.7.6 please note that editing /app/design/frontend/YOURINTERFACE/YOURTHEME/layout/page.xml is not needed any more. Please change it back to the original validation.js instead of validation-4min.js
Troubleshooting
Please review all the steps listed in this thread. It has the most common errors with solutions listed - when posting any questions please include the output of the 4 steps listed.
Don't disable the output of Fooman_Speedster under Configuration > Advanced - it will make your site unusable. To uninstall either use Magento Connect or edit /app/etc/modules/Fooman_Speedster.xml (change true to false).
Additional support can be obtained through our website.
Changelog
1.0.4 Updated bundled validation.js to newer build, minor fixes
1.0.2 Updated to newer minify build
1.0.0 First Stable Release
0.9.4 RC1 (updated to minify 2.1.2, added support for minifying skin_js) - simplified .htaccess rewriteRule (thanks to PremierWeb)
0.9.3 reversed adding subdirectory to paths
0.9.2 change in detection of subdirectory
0.9.1 correct timestamps for subdirectory installs
0.9.0 fixed bug in handling of subdirectories - .htaccess has been UPDATED!
0.8.2 removed check for Core dependency
0.8.1 automatically configure paths for multi stores
0.8.0 multi store functionality now supported - please read the documentation forum for details
0.7.16 updated to work with Magento 1.2 - form_key support, thanks jemoon
0.7.15 fixed multiple sites date stamp issue
0.7.14 reworked paths - should enhance cross-platform support
0.7.10 admin areas now supported, reworked folder handling - .htaccess HAS CHANGED!
0.7.9 set docroot for IIS - could solve image handling bug
0.7.8 fixed bug introduced with 0.7.7 - automatic handing of validiation-4min.js
0.7.7 updating to Minify 2.1.1 (support for symlinks)
0.7.6 load CSS before JS - this should allow the browser to render the page earlier
0.7.5 fixed bug introduced with 0.7.4 (load JS/CSS securely when needed)
0.7.4 non-webroot installations now handled properly (.htaccess needs to be changed accordingly)
0.7.3 handle js_css files
0.7.2 fixed bug with index.php
0.7.1 added .htaccess to /lib/minify folder to allow access
0.7.0 now with automatic versioning support, automatic configuration of used skin and proper Magento field validation

