Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
United-Forum CSS Sprites - ludicrous speed - NOW! Details »
United-Forum CSS Sprites - ludicrous speed - NOW!
Mod Version: 0.7.2, by Osbes (Member) Osbes is offline
Developer Last Online: Feb 2013 I like it Show Printable Version Email this Page

vB Version: 4.x.x Rating: (31 votes - 4.55 average) Installs: 269
Released: 12 Jul 2011 Last Update: 06 Aug 2011 Downloads: 2849
Not Supported Uses Plugins Auto-Template Additional Files Is in Beta Stage  

tl;dr Makes your forum faster.

Want an easy one-click installation for this addon? . Vote for this jira-entry

Add on currently is in beta stage

When visiting a website, speed is a very important factor not only for users but crawlers as well. Long loading times are a nuisance since your time is basically wasted during the waiting period. Hence, we are trying everything we can in order to speed up our site. One great way to improve loading times is by the use of css sprites. Unfortunately these are not implemented by vBulletin.

We therefore decided to develop our own css-sprite add on for vBulletin boards and want to share this code with the worldwide vBulletin community.

Live demo
The add on is permanently running in our vBulletin board ( > 2.000.000 posts), take a look:
http://www.united-forum.de

The add on will be supported via this thread. If you have any questions, issues, improvements or feedback regarding this add on, please feel free to post a comment or write us a pm at any time. We are happy to discuss

vBulletin performance using css sprites
Our tests are based on version 0.7.0. We used the analytic tools firebug network utility and the googlelabs.com page speed site

on the client side the following parameter were used:
download speed: 5.7 MBit/s
ping: 31ms




css sprites - what are they?
The intention behind css sprites is the bundling of many small graphics into one large graphic in order to decrease the number of required http requests. This shortens the loading times of the given website. In addition, the the accumulated size of all small graphics is higher than the size of the sprite due to reasons of compression.
You can find further information in a great article by Chris Coyier.
What is the gain in using css sprites?
Aside from the technical implementation, the question on how much one actually does gain by using css sprites is of the most interest. Obviously they decrease loading times - but how important are small loading times and what is the impact on vBulletin overall loading times?

A short time ago, Jasper Aguila pointed out that speed is one crucial stickiness factor in his blog on vBulletin.com.
Originally Posted by Jasper Aguila vBulletin Support
The internet has unfortunately contributed to the exponential decrease in attention span for many individuals. That's why this decade is seeing a trend in emerging technologies emphasizing the importance of speed request. It's crucial for your content to be promptly distributed in a timely manner, else bounce rate will increase - making you lose returning visitors. It's also important to note that slow sites may be penalized by search engines.

With better browsers, more powerful processors, and improved technologies constantly releasing each year, it's becoming quite difficult to provide excuses for slow loading pages. Therefore, try optimizing your server for speed. Read up and learn optimization techniques at vBulletin.com's Server Configuration forum.
In addition, the google ranking is influenced by the site speed as well.

Google Webmaster Central Blog
Originally Posted by 09.04.2010 - Google Webmaster Central Blog
You may have heard that here at Google we're obsessed with speed, in our products and on the web. As part of that effort, today we're including a new signal in our search ranking algorithms: site speed. Site speed reflects how quickly a website responds to web requests.
vBseo Webmaster Mert Gökçeimam
CSS sprites is a huge bonus for big boards , any big board owner definately should use it.
Last but not least, not only the user's loading time is reduced, but also does the server load decrease as the server will have to handle a lot less of http requests. This clears available connections and cpu time.
Add on features
In the current released beta version 0.7.2, sprites are available for FORUMHOME and FORUMDISPLAY. Coming up next SHOWTHREAD.

Sprites are created style based for all forum styles and saved in a folder which you can set via the imgdir_sprite stylevar. You have one additional button in the ACP (CSS-Sprites -> Refresh) which automatically creates all sprites, the according css definitions and includes those css definitions in the vBulletin css rollup files.
Installation

First of all, if you didnt want to change the templates manually, install the Template Modification System (TMS). Now proceed with the installation:
  • upload the contents of the upload folder into your forum home directory.
  • import the add on in the ACP
  • upon installation a new stylevar imgdir_sprite will be created. Update this stylevar based on your file structure - default value is the vbulletin sprite directory. Make sure the folder is writable, else the sprites can't be saved!
  • create the sprites via the ACP at CSS-Sprite using the Refresh option.
  • If you have installed TMS, you are done now. This was an easy gained speed up, not? If you didnt installed TMS and didnt want to do it, proceed with the next point:
  • in order to use the sprites, you then will have to edit some templates. The diffs (xou will find it in the do_not_upload folder show which parts you have to delete '<' and which parts to add '>' In addition, on top find the lines in which you will find the respective code.[/b]

Download Now

Only licensed members can download files, Click Here for more information.

Supporters / CoAuthors

Screenshots

Click image for larger version

Name:	forumdisplay_default.jpg
Views:	2175
Size:	151.3 KB
ID:	131565   Click image for larger version

Name:	forumdisplay_sprites_070.png
Views:	1586
Size:	70.8 KB
ID:	131566   Click image for larger version

Name:	forumhome_default.jpg
Views:	1279
Size:	145.6 KB
ID:	131567   Click image for larger version

Name:	forumhome_sprites_070.png
Views:	1136
Size:	66.6 KB
ID:	131568  

Click image for larger version

Name:	nachher_forumdisplay.jpg
Views:	1523
Size:	96.6 KB
ID:	131570   Click image for larger version

Name:	nachher_forumhome.jpg
Views:	1145
Size:	94.1 KB
ID:	131572  

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 12 Jul 2011, 22:51
Osbes's Avatar
Osbes Osbes is offline
 
Join Date: Jul 2008
Frequently Asked Questions

Question
My Icon (mostly the paperclip) looks like http://dl.dropbox.com/u/246391/Robin_result.png (it is stretched and vertical lines are added), what can i do?
Answer
I assume you use a GD Libary older than 2.0.36.

GD had a problem handling grayscale images with alpha channel correctly, which was fixed with GD 2.0.36 in the year 2007.

The solution is to update the GD-Libary to 2.0.36 (or later) or replace every file which uses "gray+alpha" with an version using "color RGBA".
I would advise to update the GD-Libary, cause there is also a serious security problem, that was fixed by Debian in the year 2009.

For the embed Version of GD within PHP, this issue is fixed since PHP 5.3.0.
Question
Does this addon works with CDNs?
Answer
Yes. This addon has one side support for CDNs. One side meaning we can't write the sprite on your external server (and never can). But it doesn't has any problems reading the icons out of your CDN and writing it to a local filepath where your CDN sync function can distribute it to your CDN.
Question
How to add custom icons into the sprite?
Answer
The addon has the option to include custom icons. Be warned it's meant for advanced users (and style designers). An explanation can be found here:
http://www.vbulletin.org/forum/showp...&postcount=177
Question
I am using an Add-On for changing the forum icons (like www.vbulletin.org/forum/showthread.php?t=244351). When using CSS Sprites, my forum icons are reverted to the original state.
Answer
The feature to use forums custom icons is builtin in vBulletin 4. You can add to every forum an own imageprefix, so it will use forums custom icons. If you use the vBulletin imageprefix for your your forums, these icons will instantly added to the sprite.

An explanaition to this can be found in the vBulletin Manual (under Prefix for Forum Status Images):
https://www.vbulletin.com/docs/html/...orum_add_forum
Question
Google pagespeed still tells me that i should combine icons into sprites.
Answer
Despite covering hundreds of icons our addon can't cover everything. Especially gradients can't be automatically replaced since they differ a lot in custom styles. But, we do offer a hook so you can add your own icons into the sprite, based on the needs your board has.
A longer answer why we can't include gradients and all custom icons can be found here
http://www.vbulletin.org/forum/showp...2&postcount=49

To add the missing Icons yourself, please read: How to add custom icons into the sprite?
Question
Double background issue/ search icon dissapears
Answer
Some custom styles do include their own background, for example behind the search icon.
Since sprites replace the icons with the sprite background this gets in the way.
Solution: Modify your search icon to include both background and icon and refresh the sprite.

Last edited by Osbes; 08 Feb 2012 at 12:30.
Reply With Quote
  #3  
Old 12 Jul 2011, 22:51
Osbes's Avatar
Osbes Osbes is offline
 
Join Date: Jul 2008
Version 0.7.2 (06.08.2011)
  • now supporting folders for forum prefixes
  • sprite generation splittet to avoid timeouts on sites which a huge number of styles
  • checks if the gd version is 2.0.36 or higher (experimental)
Version 0.7.1 (01.08.2011)
  • added support for search.php pages including What's New
  • some minor bugfixes
Version 0.7.0 (01.08.2011)
  • full support for ltr/rtl
  • forum sidebar support added
  • FORUMDISPLAY support added
Version 0.6.3 (23.07.2011)
  • Added the possibility to use TMS for automatic template modification.
  • Icons can now be merged into different sprites and css rollups instead of one big sprite.
  • Addon is now compatible with vBulletin 4.1.x
Version 0.6.2 (17.07.2011)
  • Added support for http filepaths and therefore one-way support for CDNs
  • Templates are now using the cache system
  • clientscript/sprite_vbulletin_collapse.js removed.
Version 0.6.1 (17.07.2011)
  • bug-fix: using alternative paths for post icons could cause that these are not includes in the sprite.
Version 0.6.0 (17.07.2011)
  • possibility to add custom icons into the sprite via plugin-hook sprite_add_icon
  • added log output during sprite generation in the acp
  • option to deactivate using post icons in your sprite (default should be on)
Version 0.5.1 (12.07.2011)
  • Added support php versions < 5.3.0. Addon now just requires php5 due to TypeHinting
Version 0.5.0 (12.07.2011)
  • Add-On release
  • FORUMHOME css-sprite support

Last edited by Osbes; 06 Aug 2011 at 20:10.
Reply With Quote
  #4  
Old 12 Jul 2011, 23:20
Jeff Ledger Jeff Ledger is offline
 
Join Date: Jun 2011
Let's say

The goal is good but it's hard for other forums using different styles than yours use it.

Sprite require the css must be 100% exactly, and if someone use custom icons they will need to make a different sprite also the css.

It takes even more time than the usually way to reedit sprite and css.

I prefer doing sprite css for every single style, means custom css and custom sprite png. This is more effective and useful than a product like that.

Btw nice mod. Keep up the good work

Jeff
Reply With Quote
  #5  
Old 12 Jul 2011, 23:31
Mooff Mooff is offline
 
Join Date: Mar 2010
The goal of our Add on is to solve that problem. The Add on creates a different sprite for each style based on the used icons, their dimension (hight width) and vbulletin stylevars.

We are using 9 different styles (not counting our mobile styles) and it works without problems in all of them. Without additional refinement.


The intention is to create an addon where the board admin doesn't have to know anything about html or css and still can use sprites.
Reply With Quote
  #6  
Old 13 Jul 2011, 10:40
Hornstar's Avatar
Hornstar Hornstar is offline
 
Join Date: Jun 2005
Real name: Matt
Originally Posted by Mooff View Post
The goal of our Add on is to solve that problem. The Add on creates a different sprite for each style based on the used icons, their dimension (hight width) and vbulletin stylevars.

We are using 9 different styles (not counting our mobile styles) and it works without problems in all of them. Without additional refinement.


The intention is to create an addon where the board admin doesn't have to know anything about html or css and still can use sprites.
Awesome! Can't wait to test this then.

Thanks.
Reply With Quote
  #7  
Old 13 Jul 2011, 11:13
Jeff Ledger Jeff Ledger is offline
 
Join Date: Jun 2011
The goal of our Add on is to solve that problem. The Add on creates a different sprite for each style based on the used icons, their dimension (hight width) and vbulletin stylevars.

We are using 9 different styles (not counting our mobile styles) and it works without problems in all of them. Without additional refinement.


The intention is to create an addon where the board admin doesn't have to know anything about html or css and still can use sprites.
Sounds promising, will test it and give you feedbacks.

Jeff
Reply With Quote
  #8  
Old 14 Jul 2011, 03:39
final kaoss final kaoss is offline
 
Join Date: Apr 2006
Yeah it sounds like it has some potential
Reply With Quote
  #9  
Old 14 Jul 2011, 16:41
Barbaro Barbaro is offline
 
Join Date: Apr 2008
guau 4.1.4?

gracias
Reply With Quote
  #10  
Old 14 Jul 2011, 17:51
Mooff Mooff is offline
 
Join Date: Mar 2010
I guess you want to know whether it does work with 4.1.4?

We can't test it for ourselfs, since we are going to jump 4.1.4 and update with the release of 4.1.5.
BUT on the german ( www.vbulletin-germany.org ) modding site we received feedback that this addon does work well with 4.1.4


Regards Mooff
Reply With Quote
  #11  
Old 14 Jul 2011, 20:06
Barbaro Barbaro is offline
 
Join Date: Apr 2008
Exactly, it hurts, I will be pending for 4.1.5.

Good mod, thanks

regards
Reply With Quote
  #12  
Old 15 Jul 2011, 05:08
cherylferraro's Avatar
cherylferraro cherylferraro is offline
 
Join Date: Oct 2005
Not working for me but I think this will be fantastic when it's fully functional. Thank you for working on it
Reply With Quote
  #13  
Old 15 Jul 2011, 08:00
Mooff Mooff is offline
 
Join Date: Mar 2010
While posing a bug report please include
- vBulletin Version
- full bug description (what, where, whether you did the template edits ...)
(if possible link to your site where the addon is active)

so we can fix whatever the problem is.
Reply With Quote
  #14  
Old 15 Jul 2011, 17:23
cherylferraro's Avatar
cherylferraro cherylferraro is offline
 
Join Date: Oct 2005
VB version 4.1.4 patch 1

Bug description: Uploaded the files and did the template edits on a test style. Set 777 permissions on sprite folder and refreshed CSS-Sprites via admincp. No sprites were generated, or if they were they were not added to the images/sprites folder. I can't find the sprites. I guess it goes without saying that the status icons were not displayed on forumhome.

I tried uninstalling and then reinstalling. It still didn't work.

Thanks again for your work on this mod. It will be a great addition to vb.
Reply With Quote
  #15  
Old 15 Jul 2011, 17:53
Osbes's Avatar
Osbes Osbes is offline
 
Join Date: Jul 2008
Are you using the PHP GD Libary? This addon currently doens't support ImageMagick.
Which Version of the PHP GD Libary is installed?

If you are currently not using the PHP GD Libary or it is older than GD2, please install/update GD and try it agein.

If you are using GD2, please send me via PN the output of

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

and the output after refreshing the css-sprites via admincp.

If possible, please check your php error-logs if if some errors related to the sprite.php occurred.




Big Big Thanks for the nice feedback

Last edited by Osbes; 15 Jul 2011 at 19:17.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 11:43.

Layout Options | Width: Wide Color: