'#' Character Breaks Query String

edited February 25, 2019 in Questions
I noticed a glitch in my query string passed for creating new contacts. When the billing address has '#' in it, the user gets the "Inked" error message. 

For example, the street address "2799 WEST GRAND BLVD" works fine; however, 430 BEDFORD ST #100 MA does not. And I narrowed the problem down to '#' being the issue.

I've attached my Query string below but does any have suggestions for how I should move forward? I could always put limitations on entry for symbols but i'd like to not limit users whenever possible. 

AccountId={{$Model.Account.data.0.Id}}&MailingStreet={{$Model.Account.data.0.BillingStreet}}&MailingCity={{$Model.Account.data.0.BillingCity}}&MailingState={{$Model.Account.data.0.BillingState}}&MailingPostalCode={{$Model.Account.data.0.BillingPostalCode}}&Phone={{$Model.Account.data.0.Phone}}&MailingCountry={{$Model.Account.data.0.BillingCountry}}

Comments

  • edited February 25, 2019
    I think you need to encode your url so it handles the special characters, like a #.  This thread may help: https://community.skuid.com/skuid/topics/redirect-to-url-with-url-encoding-for-special-characters
  • edited December 21, 2016
    This was exactly what I was looking for, thanks for the suggestion! Didnt know where to start with this one but it completely makes sense now.

    The updated query string is below
    AccountId={{$Model.Account.data.0.Id}}&MailingStreet={{#urlEncode}}{{$Model.Account.data.0.BillingStreet}}{{/urlEncode}}&MailingCity={{$Model.Account.data.0.BillingCity}}&MailingState={{$Model.Account.data.0.BillingState}}&MailingPostalCode={{#urlEncode}}{{$Model.Account.data.0.BillingPostalCode}}{{/urlEncode}}&Phone={{$Model.Account.data.0.Phone}}&MailingCountry={{$Model.Account.data.0.BillingCountry}}
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!