Skip to main content
September 26, 2017
Question

Decode URI component using velocity script

  • September 26, 2017
  • 1 reply
  • 1816 views

Hi, is there a way do decode a URI component using Velocity Script from within the Marketo environment?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

SanfordWhiteman
Level 10
September 26, 2017

Sure, easy peasy.

#set( $decodedField = $link.decode($lead.encodedField) )

September 26, 2017

Sadly, when I make a token with just the script:

#set( $decodedField = $link.decode('Daves%20Super%20Fun%20Test%20Fundraiser') )

This is the decoded field: $decodedField

Then try and send an email with it, I get the error:

An error occurred when procesing the email Rendered_Email_Velocity_Error_Area_?!

near

?
SanfordWhiteman
Level 10
September 26, 2017

Works for me.

Did you send a real email (always use a real email to test Velocity, not a sample).