DDL-Turkey > vBulletin > VB4 SuperCharged - Optimises CSS, Javascript And HTML

VB4 SuperCharged - Optimises CSS, Javascript And HTML


25-08-2010, 23:29. Author: showstar
vB4 SuperCharged - Optimises CSS, Javascript and HTML


Minifies all CSS files and serves CSS directly, eliminating the PHP overhead from css.php. Intelligently defers javascript loading and combines common javascript files. Also features optional compression with Google Closure Compiler. Based on HELLCAT's Realtime Page Compressor, and adds complete whitespace removal around block and meta elements and removal of unimportant comments.
 
Features:

CSS Optimiser: Minifies all CSS files and serves CSS directly, eliminating the PHP overhead from css.php.

javascript Optimiser: Intelligently defers javascript loading (puts script tags just before on the fly) and combines common javascript files. Also features optional compression with Google Closure Compiler.

HTML Optimiser: Based on HELLCAT's Realtime Page Compressor, and adds complete whitespace removal around block and meta elements and removal of unimportant comments.

Attachment Optimiser: Intended for FastCGI users only - serves attachment thumbnails and images directly rather than through PHP.

All this is done efficiently and on-the-fly - no need for any template edits.

Installation:

1. Ensure you have CSS stored on the filesystem and not your database. To check this, go to
Settings > Options > Style & Language Settings > Store CSS Stylesheets as Files? and ensure it is set to "Yes".

2. Disable Remote YUI if you have it enabled. To check this, go to
Settings > Options > Server Settings and Optimization Options > Use Remote YUI and ensure it is set to "None".

3. Upload the contents of vbsc.zip to your forum root directory via FTP.
4. Ensure the files vbsc.js and vbsc.js.gz in /clientscript/ are writable (chmod).
5. Install product-vbsc.xml as a Product. (Plugins & Products > Manage Products > Add/Import Product)
6. Run Compress javascript and Compress CSS under the vB4: SuperCharged Admin CP section.
7. Check to ensure that all the settings are correct for your forum, as some of the optimisers are likely to conflict
with other poorly coded mods, and not all are turned on by default (vB4: SuperCharged > Options).

Conflicts:

* If you wish to run vBSEO along with the Attachment Optimiser, you must disable Attachment Rewrites under
URL Rewrite Settings > Forum URLs. This incompatibility is by design.
* If you run vBSEO's Cleanup HTML function, you should choose between it and vBSC's HTML Optimiser.
Running both at once is a waste of resources and may create conflicts that would not otherwise exist.

Upgrading:

1. Upload the contents of vbsc.zip to your forum root via FTP. (Overwrite the existing files.)
2. Install the new product-vbsc.xml, ensuring you have Allow Overwrite set to Yes.
Plugins & Products > Manage Products > Add/Import Product

3. Run Compress javascript and Compress CSS under the vB4: SuperCharged Admin CP section.




ONLY if you wish to use the Attachment Optimiser, something similar to this is needed in your server config (nginx):


location /customattachments {
if ($request_uri ~* .(png)) {
add_header Content-Type image/png;
}
if ($request_uri ~* .(jpg|jpeg)) {
add_header Content-Type image/jpeg;
}
if ($request_uri ~* .(gif)) {
add_header Content-Type image/gif;
}
}


Download vB4 SuperCharged
 

Download Now!