Another V3 feature available today!

More
3 years 3 months ago - 3 years 3 months ago #236 by Dom Cassone
Add default values to shortcodes

As you might know, you can use JoomFuse Short Codes to insert any mapped field into your Joomla website pages. But what happens if that field is empty? Before, without doing much work, you got a funky page with a blank where there should be data.

Not anymore! We've implemented a first release of adding default values to short codes. Simply insert the short code by clicking the JoomFuse Short code button in the editor and chose the field you want to use. Then position your cursor to the left of the closing brace, type space then the word you want for the default value and if you want, another space and the word you want for visitors to see (if it is a public page and different than the default). It would look like this:

No default: (brace)JoomFuse SomeField(brace)
Default value: (brace)JoomFuse SomeField defaultValue(brace)
Default and different Visitor value: (brace)JoomFuse SomeField defaultValue visitorValue(brace)

For example, say you wanted to personalize a page with the member's first name. You might enter this:

Hi (brace)JoomFuse FirstName Member Friend(brace),

If the member has a first name in Infusionsoft, it will be displayed like Hi Joe, but if the member is logged in and does not have a first name recorded, the page will say Hi Member,. Lastly, if they are not logged in, the page will say, Hi Friend,.

Currently the values are limited to one word with no spaces. In V3, you will be able to have default phrases. Also, we will make it easier to add the default and visitor values.

* (brace) means either { or }. I can't put them in or JoomFuse tries to fill in the short code. :)

Let us know what you think!
Last edit: 3 years 3 months ago by Dom Cassone. Reason: clarify

Please Log in to join the conversation.

Time to create page: 0.629 seconds
Powered by Kunena Forum

Ready to get started?

Get your Joomla site integrated with Keap now.

JoomFuse

© Zacaw Enterprises Inc. All rights reserved.