URL Redirect Passing Name instead of Id

  • 1
  • Question
  • Updated 3 years ago
All,

I am setting up a button that redirects to a URL.  The original URL from Salesforce is shown below.   I am trying to recreate that  in the URL field in SKUID, see second entry.  I have everything working except the highlighted piece.  How do I pass a Name instead of the Id? 


ORIGINAL
/a0G/e?CF00NC0000005EMZh=LEHIGH+VALLEY+HEALTH+NETWORK+CEDAR&CF00NC0000005EMZh_lkid=001C000000whB9n&retURL=%2F001C000000whB9n



/{{Model.keyPrefix}}/e?CF00NC0000005EMZh=LEHIGH+VALLEY+HEALTH+NETWORK+CEDAR&CF00NC0000005EMZh_lkid={{Id}}&retURL=%2F{{Id}}
Photo of Jeffrey Lawler

Jeffrey Lawler

  • 1,454 Points 1k badge 2x thumb

Posted 3 years ago

  • 1
Photo of Jeffrey Lawler

Jeffrey Lawler

  • 1,454 Points 1k badge 2x thumb
Hi All,

I was wondering if anyone had any suggestions on the above?

Thank you.
Photo of Skuidward Tentacles (Raymond)

Skuidward Tentacles (Raymond), Champion

  • 17,224 Points 10k badge 2x thumb
So it seems like the issue is you have a name with spaces and the URL replaces the spaces with + , so you can't just use {{Name}}. You could try creating a formula field in Salesforce that uses the Substitute function to replace spaces with +. Then you could merge that field into the URL. This URL overviews the substitute function.
https://help.salesforce.com/htviewhel...
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
Start by just passing the {{Name}} field into your URL.  
Then try wrapping it in URL encode tags.  Like this {{#urlEncode}}{{Name}}{{/urlEncode}}

And then go down Raymond's apporach. 

Finally - you could do the space replacement in Javascript and construct the URL there.