Opened 17 years ago
Closed 17 years ago
#346 closed Bug (fixed)
blank first line in PRE tag causes newline characters to be removed
Reported by: | David Au | Owned by: | Martin Kou |
---|---|---|---|
Priority: | Normal | Milestone: | FCKeditor 2.5 Beta |
Component: | General | Version: | FCKeditor 2.4.1 |
Keywords: | Confirmed Firefox | Cc: |
Description
This issue only affects Firefox (tested with 2.0.0.3).
When the first line within a PRE tag is blank, the newline characters in the remaining lines will be removed after clicking on the Source button several times.
- To reproduce this issue, paste the following into FCKeditor's Source view:
<pre> /*** * First line (above) is blank. * Some more text... */ public void testFunction(){ System.out.println( "abc" ); } </pre>
- Next press the Source button to return to the normal view.
- Now press the Source button two more times and you will see that the lines within the PRE tag are mangled due to the missing newline characters.
This ticket may be related to ticket #328.
Change History (4)
comment:1 Changed 17 years ago by
Keywords: | Confirmed Firefox added; pre removed |
---|
comment:2 Changed 17 years ago by
Milestone: | → FCKeditor 2.5 |
---|
Let's try to fix it for the 2.5. May be delayed if too complex.
comment:3 Changed 17 years ago by
Owner: | set to Martin Kou |
---|---|
Status: | new → assigned |
The basic issue here (line breaks being removed), has been solved with [523], which was one of the partial fix I committed for #328. So yes, these tickets are related.
While the appearance is now correct, the <br> tags added are still wrong. A <pre> tag doesn't need <br> tags for line breaks. They shouldn't be added there. I'll look for a fix in this issue.
comment:4 Changed 17 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Ok, the <br> problem is already mentioned in #404. So for this ticket alone it can be considered fixed.
Confirmed with FF2. Ok with IE6.
Without the blank line, line breaks are converted to <br> (as expected with FF, which doesn't mean it is the correct thing). With the blank lines, no <br> are placed there, breaking the code.