How to Use macro inside form

rajitha somarathna asked on January 11, 2016 11:48

I need to change boolean value "True" into "Yes" in email notification. So i am struct how to write it .

I have added the field subscribes

Image Text

I need to do some thing like this. But the way i am doing as below is wrong

Image Text

Please give me a way to do that

Correct Answer

Jan Hermann answered on January 11, 2016 16:01

;-)

{%Subscribes?"yes":"no"%}

3 votesVote for this answer Unmark Correct answer

Recent Answers


David te Kloese answered on January 11, 2016 13:56 (last edited on December 10, 2019 02:30)

Hi,

Just a quick test I came up with the following macro:

{% if (Newsletter) { "computer says jups" } else { "computer says nope" } |(identity)GlobalAdministrator%}

where Newsletter is your field name...

Greets,

David

2 votesVote for this answer Mark as a Correct answer

Pavel Jiřík answered on January 11, 2016 15:53 (last edited on December 10, 2019 02:30)

Hi, I can just agree with David. In your case simply use the following macro:

{% if(Subscribes) { "yes" } else { "no" } |(identity)GlobalAdministrator%}
1 votesVote for this answer Mark as a Correct answer

rajitha somarathna answered on January 12, 2016 05:40

thank you for the support

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.