<txp:image_url /> sing/cont tag, 4 attributes

image_url

The image_url tag is a single or a container tag that Textpattern will replace with the URL of the current image in an images list, or the specific image if given an id or name.

If used as a container tag, it must be specified as an opening and closing pair of tags, like this:

<txp:image_url>
...link contents...
</txp:image_url>

attributes

id="unset" (integer) 
  • An id assigned at upload of an image to display. The IDs can be found on the Images tab.
name="unset" 
  • An image to display, given by its image name as shown on the Images tab. If both name and id are specified, the id takes precedence.
thumbnail="0" (boolean)
  • If set to 1, will display the link to the image’s thumbnail instead of the full size image.
link="auto" 
  • Whether to hyperlink the URL or not.
  • Values:
    • 1: hyperlink the URL (if used as a single tag) or the container content.
    • 0: don’t hyperlink the URL / container.
    • auto: only apply the hyperlink if the tag is used as a container.

genealogy

Version 4.3.0

  • tag introduced
<txp:image_url /> 1 examples

Directly link gallery thumbs to main image

Used as a single tag:

<txp:images category="mammals">
   <a href="<txp:image_url />"><txp:thumbnail /></a>
</txp:images>

or as a container:

<txp:images category="mammals">
   <txp:image_url><txp:thumbnail /></txp:image_url>
</txp:images>

Other tags used: images, thumbnail