D
David
When I try to URLEncode the following example string:
Dave's Company
I get the following translation:
Dave's+Company
In other words, the apostrophe is not translated into it's ascii value
of '%27'. Now, if I try to use this string as part of a name/value
pair in a hyperlink on my page, my browser incorrectly interprets the
apostrophe as a quote ('). This results in everything after the
apostrophe being cut off when someone clicks on that hyperlink.
I would think URLEncode would encode apostrophes to avoid this issue.
However, I've found that I have to manually replaces apostrophes with
'%27' in my strings.
Is this the way it has to be or am I doing something wrong or is there
an easier way?
Dave
Dave's Company
I get the following translation:
Dave's+Company
In other words, the apostrophe is not translated into it's ascii value
of '%27'. Now, if I try to use this string as part of a name/value
pair in a hyperlink on my page, my browser incorrectly interprets the
apostrophe as a quote ('). This results in everything after the
apostrophe being cut off when someone clicks on that hyperlink.
I would think URLEncode would encode apostrophes to avoid this issue.
However, I've found that I have to manually replaces apostrophes with
'%27' in my strings.
Is this the way it has to be or am I doing something wrong or is there
an easier way?
Dave