Solved

how to escape the underscore in a link

Posted on 2010-08-12
4
394 Views
Last Modified: 2012-05-10
Hello,

I'm building a link that has an encrypted key that we generate and that key can include the underscore character.  I'm using the below link to post to some social sites and when the user clicks the link it strips off the "_".  Any ideas on how to escape this or how to build the link so that the "_" is included in the users request?

http://mysite/EDG_
0
Comment
Question by:cgray1223
  • 2
4 Comments
 
LVL 1

Expert Comment

by:earthsound
ID: 33421529
In HTML, the escape code for underscore is _
0
 
LVL 1

Expert Comment

by:boboudreau
ID: 33421583
You can try replacing the underscore with the unicode equivalent (perhaps they don't check for this value).

Any of these should work:

&#000005F
&#00005F
&#0005F
&#005F
&#05F
&#5F

0
 

Author Comment

by:cgray1223
ID: 33422574
maybe it's a facebook issue as other social sites handle it, but when I paste in http://linkcontextroot/EM6_;  the escape code doesn't get converted to the _.  I need the _ to be interpreted as a _.  I tried the Unicodes as well
0
 
LVL 1

Accepted Solution

by:
boboudreau earned 500 total points
ID: 33422724
Can you try to handle this instead on your server?  I.e., if facebook won't change &#95 or &#005F, can you decrypt those into ASCII before using that string as a key for your web application?
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many Password Managers (PM) out there to choose from. PM's can help with your password habits and routines, but they should not be a crutch you rely on too heavily. I also have an article for company/enterprise PM's.
Worried about if Apple can protect your documents, photos, and everything else that gets stored in iCloud? Read on to find out what Apple really uses to make things secure.
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question