Posted on 01/02/2015 5:48:29 AM PST by ShadowAce
Second
âThis is a testâ It isnât working.
âThis is a testâ It isnât working.
âThis is a testâ It isnât working.
straight single: ‘
straight double: “
Copying from post 123, let’s see what is displayed
straight single: â
straight double: â
Straight quotes were converted to curly either during posting or upon retrieval from database for display.
Posting of curly quotes is not handled.
What happens if we use the HTML ASCII codes for quotes?
(Ampersand+pound sign+34+semi-colon)= "
(Ampersand+pound sign+39+semi-colon)= '
"double quote"
'single quote'
“So I take it we are testing this quote malfeasance”
What happens if we use the HTML ASCII codes for quotes?
(Ampersand+pound sign+34+semi-colon)= “
(Ampersand+pound sign+39+semi-colon)= ‘
“double quote”
‘single quote’
I might as well do a test also.ðð²â
Didn’t work.
Worked for me but why go thru that hassle when you can simply type in the ‘ “ ?
It’s when you do a copy/paste that the problem occurs. In a copy paste you can delete
the copied ‘ “ and then retype it in and all should be okay. The problem is it takes
some effort to go thru a copied article and do that.
“This is a test” It isn’t working.
It IS working.
Replace smart quotes with regular straight quotes
http://dan.hersam.com/tools/smart-quotes.html
hey’ve shooed pipeline surveyors from their pastures, made anti-pipeline signs for a protest at the county courthouse and at appearances by the Virginia governor. They’ve also kept up pressure on local officials.
As the leader in this multigenerational band of family activists, Carolyn Reilly has found the experience exhilarating and bruising.
“There are days when I am in tears in frustration and exhaustion,” she said. “Then there are days when I’m fired up and ready to fight.”
From New England to North Carolina, scattered insurgencies have formed in opposition to a spider web of pipelines up and down the Eastern Seaboard as the nation’s energy industry seeks to move pent-up natural gas supplies.
Behind the pipeline boom: vast deposits of natural gas being drilled in West Virginia, Pennsylvania and Ohio and ready for shipment to U.S. and international markets.
“Essentially, the takeaway is they’re re-plumbing the whole United States,” said Timothy R. Carr, a West Virginia University geologist.
“Double-smart-quoted string”
‘Single-smart-quoted string’
An emâdash
Some Cyrillic: ÐладиÌÐ¼Ð¸Ñ ÐладиÌмиÑÐ¾Ð²Ð¸Ñ ÐÑÌÑин
Copy, paste, and repost:
âDouble-smart-quoted stringâ
âSingle-smart-quoted stringâ
An emââ¬âdash
Some Cyrillic: ÃâûðôøÃÂüøÃ⬠ÃâûðôøÃÂüøÃâ¬Ã¾Ã²Ã¸Ã⡠ßÃÆÃÂÃâøý
HTML code for the above:
<big><big><big><big>👍💲⚓</big></big></big></big>
The first two characters (the thumbs up and the heavy dollar sign) are sufficiently obscure that they don't fit into JavaScript's 16-bit character set. They require JavaScript to resort to surrogate pairs (two JavaScript characters for one dsplayed character) to represent them. That defeats the direct indexability of JavaScript strings (which were standardized prematurely). See here for details.
E.g., your three characters require 11 bytes in UTF-8 (four each for the thumbs up and the heavy dollar sign, and three for the anchor). If I copy your characters to the Mac pasteboard and paste them through a hex dumper, I get:
$ pbpaste|xxd 0000000: f09f 918d f09f 92b2 e29a 93 ...........
After the server mangles it, that comes back as ðð²â., or, in HTML:
👍💲⚓
See here to decode that 💩. What has happened is that each byte of the perfectly valid UTF-8 encoding has been replaced with a corresponding HTML entity from the ISO 8859-1 (Latin-1) set, resulting in crud. E.g., the f0 bytes have been replaced with the Icelandic eth character, and the 9f with the reserved Ÿ, a Latin Y with a diaeresis.
It takes real work to produce that unfortunate transformation. Far better just to let the browser sort out the UTF-8.
UTF-8 Rules! |
An interesting fact is that, if you post straight quotes (7-bit ASCII) in a non-HTML post, the server converts them to curly quotes (unicode, requiring three bytes of UTF-8 each). Your post displays OK, and you probably don't even notice unless your font is large or your eyes good.
But, then, if somebody quotes your post in a reply, your curlies are replaced with garbage, due to the current bug (unless your respondent edits them to straight quotes or replaces them with appropriate HTML entities (not going to happen)).
bttt
Disclaimer: Opinions posted on Free Republic are those of the individual posters and do not necessarily represent the opinion of Free Republic or its management. All materials posted herein are protected by copyright law and the exemption for fair use of copyrighted works.