Help - Search - Members - Calendar
Full Version: Question on quote'ing text
Movable Type Community Forum > Additional Resources > Tips and Tricks
Halogen
In my entries or my templates, how can I make some text look just like it does below ( an equivalent of a quote option )?

QUOTE
This is test text formated in the 'code' style
markcarey
I use the following MTMacro to do this:

CODE
<MTMacroDefine name="quote" ctag="q">
<div class="quote"><MTMacroContent></div>
</MTMacroDefine>


along with the following style in my Stylesheet:

CODE
.quote { background-color : #FFFF99;
            border : 1px solid black;
               padding-bottom : 3px;
    padding-left : 3px;
    padding-right: 3px;
    padding-top : 3px}


To use the Macro, I just surround the text to be quote in <q> and </q> tags.
adamrice
Mark's suggestion is a pretty good one, but at risk of being a nitpicker, it could be improved upon.

The Q tag is meant for inline quotes, and the BLOCKQUOTE for, well, block quotes. In fact, the Q tag is intended as a replacement for quote marks, so that locale-appropriate quotes will be used (eg "" in the USA, and «» in France).

Although IE doesn't currently support it, there's a CSS way to do this. Style the blockquote tag something like this:
CODE
blockquote {
background-color : #FFFF99;
border : 1px solid black;
padding-bottom : 3px;
padding-left : 3px;
padding-right: 3px;
padding-top : 3px;
}
blockquote:before {
content: "Quote:"; display: block;
}
Halogen
The blockquote css did the trick. Tried the bradchoate plugin, but couldn't quite figure out where the shortcuts where supposed to be stored.

Thanks both of you for your help.

btw, page with quotes is here.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.