About Image Field Markup

Allows you to use image fields inside markup languages, notably, Markdown and Textile in Processwire text fields

Category Text Formatters
Textformatter modules that provide run-time formatting for blocks of text (typically used with Text/Textarea fields).
Release StateStable
Should be safe for use in production environments. *
Authordiogo
Module Version1.0.4
Class NameTextformatterImageFieldMarkup
Compatibility2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7
Date AddedFebruary 27, 2015
Last UpdatedJune 25, 2016
Recommended ByNew recommendations may take up to 1 day to appear.

Instructions

This module's files should be placed in /site/modules/TextformatterImageFieldMarkup/
How to install or uninstall modules

README

pw-image-fields-markup

Textformater for ProcessWire fields that allows you to use image fields inside markup languages, notably, Markdown and Textile in Processwire text fields

Modules directory: http://modules.processwire.com/modules/textformatter-image-field-markup/

Support forum: https://processwire.com/talk/topic/9192-textformatter-image-fields-markup/

To apply it to a field

Add the textformater AFTER the markup language textformatter (Markdown or Textile)

To use it inside the text area

Simply use the normal image tags from the Markup language that you're writting on. In case of Markdown would be: ![alt](url) and in the url part use the form field_name:position. If you use 0 as the position, all images from the field will be shown. If you fill also the alt text, it will be used, if you leave it empty, that image description will be used instead.

Examples:

show second image from the field called "images" with and alt text of "overriding alt text":

![overriding alt text](images:2)

--

show all images from the field called "images" with their descriptions as the alt text:

![](images:0)

--

do the same with Textile:

!images:2(overriding alt text)!

!images:0!

Comments

No comments yet. Be the first to post!

Post a Comment

Your e-mail is kept confidential and not included with your comment. Website is optional.