Curly Quotes

Smart/curly quotes have been a thorn in the side for a while. When users of some browsers paste out of Word and into Movable Type (eg. for NGNO), the smart and curly quotes would come out as question marks (i.e. unrecognized characters). I had taught them to either turn off Smart Quotes or save as text, open in SimpleText or NotePad, and paste from there. They hated me for it.

Just found Brad Choate’s regex plugin, which lets your MT templates do search/replace on-the-fly. Configured it to replace curlies with straights, problem solved.

Of course, working with PHP would have been easier in a case like this — would not have needed a plugin to churn text; but the benefits of using a prefab publishing platform outweigh these occasional downsides.

Music: Wings :: Mull Of Kintyre

3 Replies to “Curly Quotes”

  1. Scot, is it possible to solve this problem a different way, by changing the text encoding of the pages as they are served? The TypePad Help FAQs seemed to imply this:

    https://www.typepad.com/t/app/control/help?__mode=kb&doc=000031

    There’s some additional information in Joel Spolsky’s article on Unicode:

    http://www.joelonsoftware.com/articles/Unicode.html (see the part about HTML encodings in the “The Single Most Important Fact About Encodings” section)

    So couldn’t you just take the typographer’s (curly) quotation marks that people are pasting in and save them, and then set the encoding for your HTML pages to be appropriate for the characters being served up?

  2. Alderete, thanks much for the Spolsky link. It actually did occur to me that a different encoding might solve the problem, but, like the developers referenced at the start of his article, I recognized that I don’t know enough about encodings to mess with them without shooting myself in the foot. A side-effice of the America-centric thinking in which I’ve been a life-long cog.

    It doesn’t seem that hard though, as Joel says, and seems it might be worth another look. It is vexing how differnetly the problem is handled by different browsers.

    Until I get it fixed *right*, at least the straight quotes are handled consistently!

Leave a Reply

Your email address will not be published. Required fields are marked *