Skip to the content
Documentation

class_icon

No ratings yet

Summary

Outputs an image tag referencing a class icon.

Usage

input|class_icon( [ size, [, alt_text ] ] )

Returns

A string containing an image tag.

Description

This operator generates an image tag that references a class icon. The name of the icon must be provided using the input parameter. The "size" and "alt_text" parameters are optional (see the description above). The operator uses the settings provided by the "icon.ini" configuration file (or an override).

Examples

Example 1

{'folder'|class_icon( 'small', 'Alternative image text' )}

The following output will be produced:

 

Contributors

Comments (2 historical)

Written by readers of the earlier documentation sites, kept as they were.

  1. Washing

    Kristof Coomans ·

    Note that the alt_text gets also gets washed by this operator, so don't wash it yourself.

Comments

Add a comment

Comments are read by a moderator before they appear.