Forums de discussion

css sprite

thumbnail
Priyanka Dhingra, modifié il y a 11 années.

css sprite

Liferay Master Publications: 501 Date d'inscription: 20/12/11 Publications récentes
I tried putting 4 images like :-

<liferay-ui:icon src='<%= themeDisplay.getPathThemeImages() + "/arrows/02_down.png" %>' message="down"></liferay-ui:icon>
<liferay-ui:icon src='<%=themeDisplay.getPathThemeImages() + "/arrows/01_left.png"%>' message="down"></liferay-ui:icon>
<liferay-ui:icon src='<%=themeDisplay.getPathThemeImages() + "/arrows/03_up.png"%>' message="down"></liferay-ui:icon>
<liferay-ui:icon src='<%=themeDisplay.getPathThemeImages() + "/arrows/09_up.png"%>' message="down"></liferay-ui:icon>

but .sprite.png is not created
as is mentioned in http://www.mslearningandconsulting.com/documents/28301/54708/Liferay+Performance
is there any other step that I am missing??
Ajeet Singh, modifié il y a 11 années.

RE: css sprite

New Member Publications: 14 Date d'inscription: 27/03/12 Publications récentes
If you are using <liferay-ui:icon> tag, it means that you are using the sprite by default. Because if you will look into the tag handler for this tag you can see that it is using the sprite image.

Now to see the sprite image (.sprite.png), the sprite image is created after deployment of the theme. Similarly for your given scenario, the sprite image (.sprite.png) might have been created in the theme images\arrows folder.

Let me know if you need more details.

Thanks Priyanka for sharing that link. it really explains many points related to performance.

Regards,
Ajeet