NSprite

This is the forum post for any questions or ideas for the sprite generator class. All feedback is welcome.

The NSprite Extension

Nice one Steve, looking forward to giving it a try!

I like the idea of image folder to css, however, I don’t like the sprite and icon classes as that seems like style information rather than html semantics. Personally, I would prefer including


the background-image:url(sprite.png);

in each css block.

Very cool though.

Hi

Just stumbled on this forum entry regarding the Nsprit extension.

It’s surely a better place for my suggestion (which I delete from the extension page):

[color=#222222][font=Arial, sans-serif][size=3]A suggestion: apply the same to ‘img’ tag images[/size][/font][/color][color=#222222][font=Arial, sans-serif][size=3]background images do not scale well, so I suggest that the extension would be extended to support ‘img’ tags while providing a method like ‘CHtml::image’.

CHtml::image would generate the html corresponding to displaying the image that is actually in the sprite (by writing a wrapper div and a div).

Also see (http://forum.alsacreations.com/topic-4-52655-1.html "discussion (external link)")

[/size][/font][/color]