Why won't quoted material inside HTML q tag display properly in Minileven theme?
When viewing my blog using the new Minileven theme, quoted material inside HTML quote tags (e.g., <q>Quoted material here</q>) is not displayed with actual quote marks.
To see this, check out my latest blog post
and look at the second paragraph. The phrase “being generous to the Democrats” should be displayed in quotation marks (actually, “smart quotation marks), and indeed this is done correctly on my usual blog theme. But in Minileven the quotation marks are not displayed.
Blog url: http://hecker.wordpress.com/
Just to be sure, does it work properly for you with standard quotation marks?
See my test post at http://frankhecker.com/2011/11/10/test-posts-with-quotes/
Using either ASCII quotes or HTML numeric character references for “curling quotes” works fine: The HTML numeric character references are displayed as is, and the ASCII quotation marks are automatically converted into curling quotation marks. (The latter conversion happens on the regular web interface as well, at least for the theme I’m using.) However using the HTML quote tags (whether nested or not) does not work; no quotation marks are displayed.
Hm, that is rather odd.
Is there any advantage to using the q tag over standard quotes?
The major advantage of using the q tag is that it automatically handles quote nesting (i.e., quotes within quotes, or even quotes within quotes within quotes, and so on) without you having to think about exactly what quotation marks to use at which point.
This is a tricky one. Take all of this with a grain of salt.
The major advantage of using the q tag is that it automatically handles quote nesting
That depends on the browser, and unfortunately not all browsers add the automatic quotes, or they don’t add them correctly. The inconsistencies are mostly with older versions of Internet Explorer, and though things have gotten better since their usage has dropped, it’s still a consideration for doing the punctuation yourself.
This exposes a shortcoming of your theme, Simpla — which is that it isn’t consistent with how it styles q and blockquote display.
For most, if not all, of our recent themes (say the last 50-60 we’ve launched since early 2010) we’ve been using a CSS technique called a “reset” that allows for consistent display of HTML elements across all browsers. Including these two quotation elements.
Minileven uses this technique, also. If you were to use switch your blog over to the latest default WordPress theme, Twenty Eleven, you’d see the same display as Minileven. Where the q element does not have auto-generated quotes around it. Which is intentional, for consistency sake.
The reason I’d argue it’s a shortcoming with Simpla is that you cannot rely on generated content (i.e. content added to the HTML screen output by browsers) to be consistent across all platforms and browsers. The reset technique, on the other hand, is much more reliable: you know that all browsers will produce the same output. You know that if you add the quotes in HTML around a element you want see double quotes on the screen.
Most HTML authors would probably argue that they’d rather have control over the output (by adding the quotes into their markup) rather than have double quotes or inconsistent display on their readers’ screens.
I won’t go into whether or not you’re using q incorrectly. That could be argued both ways. :)
For some fun reading, see:
OK, I guess the question then is: What if anything does WordPress.com officially recommend as the best way to markup quotations in blog posts? Just do ASCII double and single quotes and then let the themes do their magic? (I see that Minileven appears to be converting plain quotation marks into curly quotation marks.)
What if anything does WordPress.com officially recommend … Just do ASCII double and single quotes
Yes, that’s the best approach.
I see that Minileven appears to be converting plain quotation marks into curly quotation marks.
That’s actually a feature in core WordPress: when you publish a post several typographical filters are run on the text to improve readability. Including converting primes (straight quotes) to curly quotes.
Yes, plain quotes is the best way to go. Most newer themes take care of this automatically.
Sorry, but I have a couple more questions before I let this go:
First, I don’t necessarily want to use plain ASCII quotes because I’m planning to take the HTML for my posts and repurpose them as a ebook, and the ebook reading software won’t necessarily convert them into curly quotes like WordPress.com does. So I’d prefer to use either the HTML character entities for curly quotation marks (e.g., “ or “ for left double quotation mark) or the actual Unicode characters for curly quotation marks (e.g., using option-[ to enter a left double quotation mark on the Mac). Are any of these techniques not going to work with modern WordPress.com themes? Is one of them better than the others from a WordPress.com point of view?
Second, if I want to use a modern WordPress.com theme it looks like I’ll have to go back through all my old posts and change them to use the actual quotation marks; otherwise a lot of the new themes won’t show the quotation marks at all. Is there a recommended way to do this? I was thinking of exporting all my blog posts, editing the exported file, and reimporting. Is this the best approach?
Sorry, I messed up the formatting for the character entities. I meant, e.g., using &-ldquo-; or &-#-8220-; (without the hyphens) for left double quotation mark.
The actual q tag is fairly new to the HTML 5 schema. Are you sure that your eBook software supports it?
As for the quote tags, unicode should work. Have you tried them on your theme? I’m still particule to standard quotes myself from a compatibility point of view.
The topic ‘Why won't quoted material inside HTML q tag display properly in Minileven theme?’ is closed to new replies.