Problems with nested [quote] tags and HTML Corrector

nbz - February 14, 2008 - 19:14
Project:Bbcode
Version:6.x-1.2
Component:Code
Category:bug report
Priority:minor
Assigned:Unassigned
Status:active
Description

This is with the Drupal 6 version, so it may be a bug with the porting... but I get errors on nesting of [quote] tags...

If a quote element contains multiple lines, any nested quotes are broken out of the blockquote elements when viewing or previewing the post.

I have the bbcode filter added to the default "filtered html" filter.

#1

naudefj - February 16, 2008 - 06:12
Status:active» postponed (maintainer needs more info)

No changes were made to the regular expressions. If the problem is in version 6, it must be in 5 as well.

Can you please provide an example for us to test?

#2

nbz - February 16, 2008 - 14:15

Just tested and it is not there in BBCode with Drupal 5.5.

I input this:

[quote]awertngsl/gfnsdg

[quote]sdfgdsfgdfggfdfg

[quote]gfrdghdfsgh sdghdfh

gfhfsghfgh

[/quote][/quote][/quote]

and in Drupal 5.x I got:

<div class="bb-quote">Quote:<blockquote class="bb-quote-body">awertngsl/gfnsdg
<p></p><div class="bb-quote">Quote:<blockquote class="bb-quote-body">sdfgdsfgdfggfdfg
<p></p><div class="bb-quote">Quote:<blockquote class="bb-quote-body">gfrdghdfsgh sdghdfh
<p>gfhfsghfgh</p>
<p></p></blockquote></div></blockquote></div></blockquote></div>

In Drupal 6 I got:

<div class="bb-quote">Quote:<br>
<blockquote class="bb-quote-body">awertngsl/gfnsdg</blockquote></div>
<p>
</p><div class="bb-quote">Quote:<br>
<blockquote class="bb-quote-body">sdfgdsfgdfggfdfg</blockquote></div>
<p>
</p><div class="bb-quote">Quote:<br>
<blockquote class="bb-quote-body">gfrdghdfsgh sdghdfh </blockquote></div>

<p>gfhfsghfgh</p>

Is there a way to test without the built in html-crrector?

#3

nbz - February 16, 2008 - 14:23

Just found out how to do that. (simple really - go to "input formats" click "configure" next to the one you want to, and uncheck the "HTML corrector" option).

Unchecking this fixes the problem. Probably some bad interaction between these two then.

What order these run in? any way to change that?

#4

nbz - February 16, 2008 - 14:24
Title:Problems with nested quote tags and linebreaks» Problems with nested [quote] tags and HTML Corrector
Status:postponed (maintainer needs more info)» active

Changed title to reflect where the trouble is.

#5

nbz - February 16, 2008 - 15:59

disabling the smart line and paragraph breaks (while keeping the HTML corrector on) seems to fix this.

I will leave this open so you can decide if this is a bug or not. I am no longer sure.

#6

naudefj - March 2, 2008 - 09:33
Priority:normal» minor
Status:active» by design

No, this is not a bug. Please re-open if you think otherwise.

#7

Sophia - February 25, 2009 - 21:06

I do think it is a bug... I disabled smart line/paragraph breaks, so that is not it.

When the html corrector is OFF, nested quotes display correctly, as shown in the source code:

     <div class="content">
        <p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></p>
<p>Test 1</p>
<p></blockquote></div></p>
<p>Quote 1</p>
<p></blockquote></div></p>
<p>Nested quote 1</p>
<p></blockquote></div></p>
<p>Nested quote 2</p>
<p></blockquote></div></p>
<p>Nested quote 3</p>
      </div>

However, when I turn on the html corrector, the source code shows this:

      <div class="content">
        <p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></blockquote></div></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></blockquote></div></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></blockquote></div></p>
<p><div class="bb-quote"><b>Sophia wrote:</b><blockquote class="bb-quote-body"></blockquote></div></p>
<p>Test 1</p>
<p></p>
<p>Quote 1</p>
<p></p>
<p>Nested quote 1</p>
<p></p>
<p>Nested quote 2</p>
<p></p>
<p>Nested quote 3</p>
      </div>

Unforturtunaly, we had a forum import from phpBB and the html corrector NEEDS to be on for the forum and PM's to show correctly... and even changing the order cannot be done.

AttachmentSize
quoteright.jpg 18.88 KB
quotewrong.jpg 18.24 KB

#8

Sophia - February 25, 2009 - 21:34
Version:6.x-1.0» 6.x-1.2
Status:by design» active
 
 

Drupal is a registered trademark of Dries Buytaert.