Edit listings template tags
From Open-Realty Wiki
Each tag in the template system looks like this {tag_name}. The Following tags are available from the Edit Listing template.
| Tag | Description |
| listing_dataset | BEGINS the section for the display of each listing in the listing editor. This section of the template will be repeated for each listing. This section must be closed with {/listing_dataset} |
| image_thumb_# | Displays the thumbnail image from the listing where # is the thumbnail number you want displayed. |
| listingid | Displays the listing ID on the listing view page. |
| listing_title | This places the listing's title on the page. |
| listing_pclass | Displays the name of the property class the listing is assigned to. In cases where the listing is part of multiple classes it will show a the names separated by a comma. |
| listing_field_FIELDNAME | by using the name of a listing field defined in the listing template editor, you can call the individual field and place it on the page. For example to call the "address" field you would insert {listing_field_address} into your template, which would result in both the field caption and value being placed in your template, eg. "Address: 1600 Penn Ave." |
| listing_field_FIELDNAME_value | Works the same listing_field_FIELDNAME, except you only get the field value. eg. "1600 Penn Ave." |
| listing_field_FIELDNAME_caption | Works the same listing_field_FIELDNAME, except you only get the field caption. eg. "Address" |
| listing_field_FIELDNAME_rawvalue | Works the same listing_field_FIELDNAME, except you only get the raw field value. For example when calling the price field instead of getting "$150,000" you would simply get "150000". |
| listing_agent_last_name | Displays the listing agent's last name. |
| listing_agent_first_name | Displays the listing agent's first name. |
| listing_notes | Displays the contents of the listing's notes field. |
| listing_active_status | If the listing is active returns "Yes" otherwise returns "No". |
| listing_featured_status | If the listing is featured returns "Yes" otherwise returns "No". |
| listing_expiration | Displays the listing's expiration date. (Use with block; show_expiration_block to hide this if expiration is not used) |
| edit_listing_link | Returns the url to edit the listing for use in a link, example usage: <a href="{edit_listing_link}"><img src="images/no_lang/listing_editor_edit.jpg" alt="{lang_admin_listings_editor_modify_listing}" width="16" height="16"></a> |
| delete_listing_link | Returns the url to delete the listing for use in a link, example usage: <a href="{delete_listing_link}" onClick="return confirmDelete()"><img src="images/no_lang/listing_editor_delete.jpg" alt="{lang_admin_listings_editor_delete_listing}" width="16" height="16"></a> |
| email_agent_link | Returns the listing agent's email address |
| listing_hit_count - New in 2.4.4 | Returns the listings hit count |
| Blocks | |
| All code contained on the template inside a block will be controlled according to the block it is contained inside. This is for template designers to control the display of many fields or code by enclosing it in one simple template tag block. A STARTING block will look like a normal template tag but that block must be closed with {/TEMPLATE_TAG} The following template tags are blocks: | |
| show_expiration_block | will hide or show expiration date depending on the use expiration setting |
| Other/Miscellanous | |
| row_num_even_odd | Gets the row number and returns it as 0 or 1. This is used, in combination with the stylesheet to alternate table row colors. Proper usage of this tag in your template would be: <tr class="result_row_{row_num_even_odd}"> |
