SebTags 1.0 Documentation: Skins

Skins

The output from SebTags custom tags is completely skinnable by use of the "skin" attribute. You can use different skins for different tags or even for different instances of the same tag (even on the same page).

The following skins area available by default:

The demonstration site has the option to switch between all of those options.

Each skin applies a style sheet of the same name as the skin (silver.css, for example). The CSS file is located in the library path (the value of the "librarypath" attribute, which defaults to "/lib/") in the "skins" folder.

In addition to applying CSS to a form, a skin also sets a default value for the "format" attribute. So the "graybar" skin is semantic, while the "panels" skin is tabular.

You can also create custom skins. To do that, first create a .css file and put it in the skins folder.

If you want to create a skin called "example", with a format of "table", you would first create an example.css file in the in "skins" folder with the CSS for your skin.

Then you would use the "skins" attribute of cf_sebForm to pass in a structure about skins that you are defining.

<cfset sSkins = StructNew()>
<cfset sSkins["example"] = StructNew()>
<cfset sSkins["example"]["format"] = "table">
<cf_sebForm skins="#sSkins#">
   ...
</cf_sebForm>