PDA

View Full Version : url encoding quotations and apostrophes


madness
05-09-2002, 05:18 PM
I've done a lot of searching through the forums and various ASCII and url encoding pages and I'm coming up with a blank for how to bring in text with real quote marks e.g. “” versus inch marks "". I would also like to know the command for an apostrophe ’ versus a foot mark '.

The closest I came was on ftp://dkuug.dk/i18n/WG15-collection/charmaps/ANSI_X3.110-1983

which lists left and right quotes as U201D and U2019, respectively. An ampersand (&) at U0026 equates to %26 but does anyone know how to code in the U2s? Can this even be done?

Thanks!

madness
05-10-2002, 02:02 PM
Does no response from anyone mean that it can't be done and that now I'm doomed to eternal questioning by my design cohorts on whether I really DO know the difference between quote marks and inch marks? A sad, sad, future.

tg
05-10-2002, 03:29 PM
i think no response in this case means that everyone who has read this thread is thinkin someone else will come along who knows the answer... i can tell ya, you know more about it than i.

Fade
05-10-2002, 08:37 PM
Madness,

I've spoken to Greg Rewis (Chief Macromedia Evangelist etc.) directly about "+" signs and "&" characters and he said that those were not able to be used; no matter what you do. Something to do about them being used in a URL string etc...

Of course I tried everything I could think of anyway, just in case. (escaping with "\" & "/", escaping with html esc. character, and much more) :D

Nothing worked.

I think that quotes fall under the same umbrella.

What I would do is to put my own esc. character (e.g. "/quote/") in the txt file and then run a function on it once it was read in. Something like:

function parseForQ(value) {
value = String(value);
for(i=0; i<>value.length; i++) {
// Parse code
}
}

Sorry I don't have time to fill in the parse code but mabye someone else would care to finish it off if you can't figure it out.

Good Luck,
--FADE

Ricod
05-12-2002, 02:32 PM
I thought u'd have to use those % codes ... (like %20 is parsed a space) ... they are listed in the F1 help of Flash.

madness
06-07-2002, 04:31 PM
Thanks to the fabulous people who replied to thread number 12508 and posted the following link!

http://www.i-technica.com/whitestuff/urlencodechart.html

This is the most extensive listing of URL encoded characters I've seen on the web so far.

And for those of you looking for a quick answer, use

%93 for open quote mark, “
%94 for close quote mark, ”
%92 for apostrophe, ’
%97 for em dash, —

So excited. So excited.

Abelius
06-07-2002, 06:28 PM
Totally agree. That chart if fabulous... :)