field.def() with crlf in value

field.def() with crlf in value

LapointeLapointe Posts: 430Questions: 81Answers: 4

Hi

Is there a way to set a def for field with \n in ?

This question has an accepted answers - jump to answer

Answers

  • kthorngrenkthorngren Posts: 21,330Questions: 26Answers: 4,951
    edited January 2021 Answer ✓

    Maybe you need to escape the \ with a leading backslash, something like this:
    my newline\\ncharacter

    Kevin

  • LapointeLapointe Posts: 430Questions: 81Answers: 4

    Hi @Kevin

    Yes indeed... I need to use addcslashes because php stored var is used to set js def field value and addslashes do not the job...

    Thanks
    Regards

This discussion has been closed.