Macro/Format With Variable Parameters
I come from using the Umbraco CMS where "macros" have properties that can be changed for each instance of the macro being used. For example a lightbox would have several properties: slide folder, transition, speed, etc. These would all be customizable by the user after placing the macro within the cms content window. Is there anyway of accomplishing something like this in Cascade server?
Discussions are closed to public comments.
If you need help with Cascade CMS please
start a new discussion.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Ryan Griffith on 06 Aug, 2015 07:36 PM
Hi,
You can accomplish this using the Velocity
#macro
directive, where you create a macro with the desired parameters. You could additionally import that macro from another format.I'm not 100% sure if you can leave out parameters, but if not, you could pass in a HashMap with key/value pairs that contains your macro's options. Within your macro you would have some logic to handle validating the options.
Please let me know if you have any questions.
Thanks!
Tim closed this discussion on 25 Aug, 2015 12:56 PM.