Add it where? Is this something that the Item owner adds when creating the Showcase Item or is this a Category option setting so if you create a category called Mustang, you can set the item name to "car" and ever item that is created in that category would have the same "item_name" ?
I would like to be able to use the variable anywhere in the item.
For example:
In the html of a custom field.
Lets say we have a custom field for 'growing conditions'. For the html we have 'The growing conditions of {$itemname} are {$value}. '
The item name is 'SunFlower' and the author fills in the growing condition custom field with 'Sunny, dry & hot'.
So the html output would be: 'The growing conditions of SunFlower are Sunny, dry & hot.'
Or in a free text tab. Lets say the item is in the 'Asteraceae' category. So we could add a tab with this text: 'This showcase item is about {$itemname}. {$itemname}s are plants from the Asteraceae family.'
It would become really nifty if more variables would be available. For example for category name or for the various custom field values. Then we could do something like: 'This showcase item is about {$itemname}. {$itemname}s are plants from the {$categoryname} family. The growing conditions of {$itemname} are {$value1} and the need for water is {$value2}. {$itemname} mainly grows in {$value3}'
The TITLE of a showcase item is stored in a field called 'item_name'. This is already available everywhere via {$item.item_name} that a showcase item is rendered.
{$item.category_name} is also already available everywhere an item is rendered.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.