Creating Double-Space when generating PDF using globiflow

Comments

6 comments

  • Bill Carovano

    If you look at the source code, you'll probably see <p> or <br> HTML tags that are causing this.

    You can edit the source code (HTML) to fix this

     

     

    0
    Comment actions Permalink
  • Rainer Grabowski

    You can also remove any HTML code (<p>,<br>) that may come from the Podio fields(depends on the field type where the Mailing Address Lines are in): 
    strip_tags([(Offer) Mailing Address Line1])
    strip_tags([(Offer) Mailing Address Line2])

    0
    Comment actions Permalink
  • Urszula Kedzierski

    Rainer Grabowski Are you able to see what the issue is from the source code below:

    When looking at the source code it seems like everything is correct, with the correct amount of <br> tags but still when i go to preview the final letter it is still giving me an extra line break between Mailing Address 1 and Mailing Address 2 as if it is double spacing that one section. 

    For the strip_tags you suggested, is that supposed to go in the source code or in the actual podio field?

    I would highly appreciate if you could help me with this and thank you for taking the time to respond!

    0
    Comment actions Permalink
  • Bavo De Cooman

    Hi Ursula, 

    Podio fields sometimes contain hidden html tags which you won't see from the source code in your pdf brick. So indeed as Rainer suggested, it's best to use the strip tags function. Here's how you can do this: 

    First create a variable brick where you define the complete address section. Insert the blue tokens within a strip_tags function and add  . <br /> to start a new line:

        strip_tags([(Offer) Seller 1 Label Name]) . <br /> .
        strip_tags([(Offer) Mailing Address Line1]) . <br /> . strip_tags([(Offer) Mailing Address Line2])

    Then in the PDF, insert a token to the variable "address".

     

    0
    Comment actions Permalink
  • Rainer Grabowski

    The source code looks ok, the issue is caused by the fields (one or both of the Mailing Address fields may have a paragraph tag that isn't visible in the source code).

    What kind of field are Seller 1 Label Name, Mailing Address Line 1, Mailing Address Line2? Single line text fields, multi line text fields, calculation fields?

    The workaround you need is: 
    Before the PDF action add 3 custom variables: 
    name = strip_tags([(Offer) Seller 1 Label Name])
    mail1 = strip_tags([(Offer) Mailing Address Line1])
    mail2 = strip_tags([(Offer) Mailing Address Line2])

    Then use these 3 custom variable tokens in the PDF (instead of the field tokens)

     

    0
    Comment actions Permalink
  • Urszula Kedzierski

    Rainer Grabowski Bavo De Cooman Thank you both so much! I was finally able to get it to work using the 3 separate variables. Appreciate you both taking the time to respond!

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk