Using line break in "textfield" in a confiform leads to error trying to create a jira ticket

Can Kilic February 22, 2024

In my Confiform i used the "text" field which I mapped to the "description" in a jira Ticket. Because I wanted to see the hole text I changed the "text" field to "textfield" field. Here a user can also use a line break and doesnt have to enter the text on just 1 line. When a user uses this line break he gets an error message:

Could not prepare JSON: ............. Invalid format. Expected a ',' or '}' at 157 [character 37 line 9]

How can I still use the "textfield" without getting an error message.

1 answer

0 votes
Alex Medved _ConfiForms_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 22, 2024

Hi @Can Kilic 

Consider using escapeJSON function to ensure the value that you accept from users are properly escaped and dont break your JSON

Alex

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events