• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: How do I display checkbox values in admin email?

How do I display checkbox values in admin email? 13 years 10 months ago #10743

  • timburkart
  • timburkart's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 6
  • Thank you received: 1
What syntax should I use to display the value of a checkbox in the admin email? I have tried both {checkbox1} and {checkbox1:value}.
The administrator has disabled public write access.
The following user(s) said Thank You: Ronald1947

Re:How do I display checkbox values in admin email? 13 years 9 months ago #10779

  • p33rZA
  • p33rZA's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 1
What is the correct syntax that needs to be used in Checkboxes, Radiogroups and Dropdowns

When creating a checkbox group, a radio group or a selectbox, you need to use a specific syntax inside the default value textbox.

Let's assume that you have a checkbox group and want to display 3 cities, Paris, London, Milan. Your syntax should be:

Paris|Paris,London|London,Milan|Milan

Why the duplicated words? That's because you can set the field to show something to the user, and return something else to you. For instance, if you want your checkbox group to return the country, but show the user the cities, you should use:

France|Paris,UK|London,Italy|Milan

This way, the user will see Paris, London and Milan, but you'll get France, UK, Italy in the backend, in the thank you message and in the emails.

You can also use the {checked} syntax to make some options selected by default:

Paris{checked}|Paris,London|London,Milan{checked}|Milan

This example will select by default Paris and Milan when the form is initially shown to the user.
The administrator has disabled public write access.
The following user(s) said Thank You: jmarden

Re:How do I display checkbox values in admin email? 13 years 9 months ago #10806

  • timburkart
  • timburkart's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 6
  • Thank you received: 1
I don't have a checkbox group. I have four checkboxes where I want to know yes/no, true/false, on/off... whatever whether each box has been checked. Perhaps someone could create a screen print of the correct checkbox definition because I am not understanding the documentation or the explanation posted by p33rZA.

Thank you!!
The administrator has disabled public write access.

Re:How do I display checkbox values in admin email? 13 years 9 months ago #10873

  • bogdanc
  • bogdanc's Avatar
  • OFFLINE
  • Moderator
  • Posts: 669
  • Thank you received: 11
Hello,

The correct syntax that should be used is {field_name} where "field_name" is the name/id of your field in the form.
The administrator has disabled public write access.

Re:How do I display checkbox values in admin email? 12 years 8 months ago #14296

Great tip!
And to add to it: if you add <br /> tags within a checkbox group that allows multiple options the options will be listed in the email. Example...

This...
France<br />|Paris,UK<br />|London,Italy<br />|Milan

Appears as...

France
UK
Italy

Instead of France,UK,Italy

:cheer:
The administrator has disabled public write access.

Re:How do I display checkbox values in admin email? 12 years 7 months ago #14584

  • futugle
  • futugle's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 1
Hi.

That does not work. Even if I put in the fieldname of the checkbox, and check it, the respons e-mail will come up with a blank for content. Any other ideas?
The administrator has disabled public write access.

How do I display checkbox values in admin email? 10 years 11 months ago #22996

  • vonkraut
  • vonkraut's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 1
To other people looking with the same problem. I had a single check box not a group and wanted to know how to get something returned when it was checked. I found out you can use the syntax from p33rZA 's comment on a single check box in the items list if you type something like Yes| This will send yes as a value if the box is checked in an email, but won't display anything as a label for the check box.
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!