Widget -> Item List -> List Module Templates

sekeri
sekeri
@ilker
9 years ago
334 posts
I can select/use different templates in an item list for a widget. How can I create and use my own list templates in a list widget for different modules?
widget.jpg
widget.jpg  •  168KB


updated by @ilker: 12/22/16 11:55:59AM
brian
@brian
9 years ago
10,148 posts
That's a good question :)

Off the top of my head I don't think you can at this time - you'd just want to add your template in as the "template code". We can certainly look into a way to do this in a future release, but that would likely be an update to the core template system that would allow you to create your own templates via the ACP.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
michael
@michael
9 years ago
7,714 posts
Couple of ways to do it.

* select the CUSTOM option from the TEMPLATE dropdown and add your code in there directly.

If you have a custom template that actually exists in the file system in your current skin, then you can add that option by using the "Template Code" widget instead. The code that the "Item List" widget would use is shown to you there, so you can copy that over to the "Template Code" widget and add the name of your template in there.

(see the 2 screenshots)
sekeri
sekeri
@ilker
9 years ago
334 posts
Quote: The code that the "Item List" widget would use is shown to you there, so you can copy that over to the "Template Code" widget and add the name of your template in there.

Using a custom template that actually exists in the file system via "Template Code" looks like the best option. But I could not get what exactly you mean with the sentence above?
michael
@michael
9 years ago
7,714 posts
That means, if you dont want to form the correct structure yourself using the docs from here:

"{jrCore_list}"
http://www.jamroom.net/the-jamroom-network/documentation/development/89/jrcore-list

That the structure of the current list is shown to you in at the bottom of the "Item List" widget.

See that part in the screenshot that is highlighted in the section TEMPLATE CODE? That is the code you would use to do the same thing in a template.

The widget called TEMPLATE CODE accepts that code (its the same as typing in a .tpl file).
sekeri
sekeri
@ilker
9 years ago
334 posts
Thanks Michael! Actually I already know it. I hope you can also provide the functionality I mentioned in my first post. I think It would be really helpful to make a collection of our own widget templates and easily use and switch between them.

Tags