This project is read-only.

XSLT Extension - Media

The Media library XSLT extension can be used to ease those often tricky situations in XSLT.

Enabling the XSLT extension for use in your XSLT templates.

Add the following XML snippet to your ~/config/xsltExtensions.config file:

<XsltExtensions>
	...
	<ext assembly="uComponents.Core" type="uComponents.Core.XsltExtensions.Media" alias="ucomponents.media" />
	...
</XsltExtensions>

Methods

Here are available methods:

Method Returns Notes
GetImageHeight(String) Returns the height of the image. Gets the height of the image.
GetImageHtml(String) Returns a HTML image tag from a Media Id. Gets the HTML for an image tag, using the Media Id.
GetImageHtml(String, Int32, Int32) Returns a HTML image tag from a Media Id. Gets the HTML for an image tag, using the Media Id.
GetImageWidth(String) Returns the width of the image. Gets the width of the image.
GetMediaByCsv(String) Returns an XPathNodeIterator of the media nodes from the CSV list. Gets the media by CSV.
GetMediaByCsv(String, Boolean) Returns an XPathNodeIterator of the media nodes from the CSV list. Gets the media by CSV.

Last edited Oct 24, 2011 at 1:56 PM by leekelleher, version 6