| templateitemlist |
| This command allows a different approach to the listing of items. It
loops 'itemcount' times and uses 'template' to create the HTML to list.
'template' contains HTML and can contain a series of special macros that
will be replaced with specific info about the item. The item list also
stops if no more items are available. |
| |
| Here are the macros that can be included in the template: |
| ##COUNT## - Replaced with a counter starting at 0 |
| ##NAME## - Name of item |
| ##ESCNAME## - Name of item (URL Encoded) |
| ##PRICE## - Item price (use the 'pricelevel' argument to select level) |
| ##HOT## - Will be replaced with contents of 'hottmpl' argument if hot |
| ##SALE## - Will be replaced with contents of 'saletmpl' argument if sale |
| ##LONGDESC## - Long description |
| ##SHORTDESC## - Short description |
| ##TINYDESC## - Tiny description |
| ##PHOTO## - URL to item photo |
| ##TNPHOTO## - URL to tiny item photo |
| ##PARTNO## - Item part no |
| ##FEATURE## - Replaced with item feature |
| ##FEATURE2## - Replaced with item feature 2 |
| ##DATE## - Replaced with item date (MM/DD/YYYY) |
| ##DATEMONTH## - Replaced with item date month |
| ##DATEMDAY## - Replaced with item date month day |
| ##DATEYEAR## - Replaced with item date year |
| ##ID## - Replaced with item ID |
| ##CLI_ID## - Replaced with item owner client ID |
| ##EMP_ID## - Replaced with item owner employee ID |
| ##SALEPRICE## - Replaced with item sale price |
| ##UNIT## - Item unit field |
| ##ALT## - This will alternate between 0 and 1 |
| ##FILE## - Item File |
| ##RELAUTHCOUNT## - number of authorized releases for this item with the associated passed ref_no in an open order (prev_line_refno has to be there in load command or else this is 0) |
| ##REFNOCOUNT## - number of times this item occurs in an open order with the associated passed ref_no field (prev_line_refno has to be there in load command or else this is 0) |
| ##RELEASECOUNT## - number of times this item has been released in an open release order (countreleases has to be "yes" in load command or else this is 0) |
| ##PREVLINECOUNT## - number of times this item shows up in a previous open release order |
| ##LASTRELDATE## - the last date this item was released in a release order |
| ##ALTCATCOUNT## - count of alternative categories |
| |
| Arguments: |
| itemcount - Number of items to display (default=10) |
| template - The main HTML template as described above (required) |
| hottmpl - Template to display for ##HOT## |
| saletmpl - Template to display for ##SALE## |
| pricelevel - Price level for ##PRICE## (default=0) |
| blankimage - Image to use if no photo or tinyphoto exists (default=blank.gif) |
| jsescape -Whether to jsEscape the results (default=no) |
| usefile - Whether to load the file (default=no) |
| filebackend - Whether to force laoding the file from the back-end location (default=no) |
| |
| Returns how many items were actually printed or "error:..." if an error occurred. |