[TYPO3-RTE] making quotations easier

Uschi Renziehausen typo3news at otherone.de
Mon Jul 10 23:49:41 CEST 2006


Hi Robert,

Robert Markula wrote:
> Robert Markula wrote:
>> Hello list,
>> As far as I can see, there is currently no easy way in to mark text as 
>> quote ('blockquote' or 'q') in htmlarea RTE. For the purpose of 
>> increased accessibility as well as a clean, semantic markup, it should 
>> be easier to mark text as a quote ('q') or blockquote ('blockquote') - 
>> especially since quotations are not uncommon on websites.
>>

There is a very easy, even too easy (and wrong) way to create a 
blockquote, as long as you have set useCSS = 0 OR are using IE. Simply 
press the 'Increase Indent' button.
Inserting inline elements like 'q' is far more difficult, and needs the 
QuickTag-Plugin to be available.

>> Three things that could make an implementation a little bit challenging:
>> - <blockquote> requires that the iincluded text is enclosed with a 
>> block element, e.g. <blockquote><p>This is a quote</p></blockquote>.

blockquote is treated like this by browsers and T3s transformations 
alike on all ways.

>> - On the other hand, the <q> element requires to be enlosed within a 
>> block element, e.g. <p>The following text is a quotation: <q>May the 
>> force be with you!</q></p>

That is true, but: Usually your content area is surrounded by some block 
element (W3C usage of the term block element).

>> - Optionally quotations (be it either blockquote or q) can be 
>> referenced, e.g. <p>The following text is a quotation: <q 
>> cite="http://www.starwars.org/">May the force be with you!</q></p>
>>
>> Would that be worth a feature request?
>

No, not this way: Never ever you want to mix up block elements with 
inline elements for several reasons:

1) Each and every word processor I know (ms word, oo writer, word 
perfect, nota bene) differenciates between block and inline elements. 
rtehtmlarea should do it in the same way!

2) Why should we have an extra popup you have to wait for to turn up? 
Just have a select list like the one you have for block elements, name 
the elements you can choose in a way everyone can understand. Why? This 
way you can finally implement the inline elements you might need in an 
organised way. No point to have even more hieroglyphs people tend to not 
understand. We have been living with letters for quite a while now! 
Organise inline elements like block elements.

> Today I thought of how this could actually be implemented. A possible 
> scenario could be:
> The user would mark the text he'd like to mark as a quote. Then he 
> clicks a button and a properties dialog window pops up, similiar to the 
> one that pops up when inserting a link. Here the user can choose to mark 
> the text as a blockquote (<blockquote>) or a citation (q) using tabs. On 
> either tab he can either click a submit button without further action or 
> optionally enter the source of the quote.

Uschi's vision:

___________
<blockquote>: Choose block element select list and choose 'Quotation block'.
- If you have selected paragraphs (<p>), wrap the selected elements with 
<blockquote>. If not: let blockquote just behave like it does now.
- If nothing is selected and we are inside <p> wrap the <p> with  blockquote
- If we are in the very first line of the editor and <blockquote> is 
selected, create <blockquote><p>|</p></blockquote>

___________
<quote>: If author has selected some text and chooses label 'Quotation' 
from inline select list, wrap with <quote>|<quote>.


___________
cite="something"
Currently, the cite attribute does not have any effect in any browser. 
For the good ones (you know there is the ONE we all love dearly) you 
cannot use any before/after css declarations to dispay the cite 
attribute. So how to cope with that one? You will not even be able to 
see what you have defined in RTE.

Prosit, Uschi (who is really somehow bewildered by transformation 
procedures)
> 
> For the correct processing this should suffice:
> RTE.default.proc {
>   allowTags = ..., blockquote, q, ...
>   allowTagsOutside = ..., blockquote, ...
> }


> 
> Ideas?
> 
> Cheers,
> Ro



More information about the TYPO3-project-rte mailing list