PHP Template Function: StdCatImage
Posted by Mark [Elevated X Support] on 22 April 2015 12:05 PM
|
|
Description: This will print an image for a specific set that is passed to it. Common Location: /cms_admin/phptemplate/<templatefolder>/functions/standard.tpl Usage: <?php foreach ($tags as $tag) { ?> <?php StdCatImage(array("category" => $tag, "usepriority" => "34", "alt" => "", "class" => "update_thumb thumbs")); ?> <?php } ?> Arguments There is only one argument that is passed to StdCatImage(), however, it is an associative array with the following possible elements: category: This is an array containing all of the metadata for a category (which comes from the CMS) Output Here's an example of the output this function will do: <img src="/members_php/content//contentthumbs/7-cat.jpg" id="set-target-43" alt="" class="update_thumb thumbs stdimage" src0="/members_php/content//contentthumbs/7-cat.jpg" cnt="1" v="0">
| |
|