How to add line break/shift when pre-populating or putting hint in a value for a field.

  • Frix
    Asked on September 22, 2016 at 2:55 PM
  • Boris
    Replied on September 22, 2016 at 5:07 PM

    When you are prepopulating forms with URL parameters, any special characters must be URL encoded:

    http://www.w3schools.com/tags/ref_urlencode.asp

    When URL encoding a character, it is turned into its URL friendly counterpart. To have a new line prepopulated with a new line character, you can simply use %0A wherever you need a new line. Similarly, you can use %20 in place of a "space" character.

    Simply put, this text:

    line 1
    line 2

    Can be represented by:

    line%201%0Aline%202

    Here is an example of prepopulating field Tilstede of one of your forms, where prepopulated text is split across different lines:

    https://form.jotformeu.com/form/62654760211350?tilstede=line%201%0Aline%202

    If you need further assistance, please let us know.