I want to have a cite underneath my blockquote, that has a certain style.
"Blockquotes are an essential part of a fancy website."
â Cite
The markup should look like this:
<blockquote><p>Blockquotes are an essential part of a fancy website."</p>
<cite>Cite</cite></blockquote>
But the WYSIWYG-Editor does not offer me the possibility to define a cite for the blockquote. And I can’t force my users to write the HTML by hand.
Is there a way to make the WYSIWYG-Editor generate the required markup?
The TinyMCE Custom Styles Codex Page should get you through this.
There are code snippets on that page, but, as an overview, the process requires two steps:
If this were me, I would consider also removing the blockquote button from TinyMCE and then adding
blockquote
as an option in the styleselect along withcite
. Doing it that way means your editors can find the correct markup for an entireblockquote
in one place.And I hope this goes without saying, but make sure to implement a custom
editor-style.css
file so that theblockquote
andcite
styles match the theme output.