Random Image Plugin (txp:mem_randimg)
Category: Projects
Posted:
I created a plugin to randomly fetch an image from a list of categories and then populate a form with its values.
file:
mem_randimg.txt [6.52kB]
Category: Textpattern
download: 2039
Textpattern plugins can be downloaded from Bitbucket
| Tag (wrap with < and > | Result |
| txp:mem_img | An html img tag that contains alt, height and width for the image. |
| txp:mem_img_url | A url path from the root to the image. |
| txp:mem_img_thumbnail | An html img tag that contains alt, height and width for the image’s thumbnail. |
| txp:mem_img_thumbnail_url | A url path from the root to the thumbnail. |
| txp:mem_img_caption | The image’s caption. |
| txp:mem_img_alt | The specified ALT value for the image. |
| txp:mem_img_category | The image’s category. |
| txp:mem_img_width | The image’s width. |
| txp:mem_img_height | The image’s height. |
| txp:mem_img_author | The name of the image uploader. |
| txp:mem_img_date | The date the image was uploaded. |
Edit 6/23/2004: Added below example form
Image:
Url:
Thumbnail:
Url:
Caption:
Alt:
Category:
Width:
Height:
Author:
Date:
Url:
Thumbnail:
Url:
Caption:
Alt:
Category:
Width:
Height:
Author:
Date: