[drupal-support] adding code / keeping <pre>-formatted code
Volker Wegert
mail at volker-wegert.de
Wed Mar 2 17:47:05 UTC 2005
Richard Eriksson <bryghtrichard at gmail.com> writes:
> On Tue, 01 Mar 2005 20:10:57 +0100, Volker Wegert <mail at volker-wegert.de> wrote:
>> has anybody ever encountered the problem I'm just facing? I'm trying to use
>> Drupal with the FCKEditor module to enable users to copy&paste little
>> interesting pieces of code into drupal. However, something along the way seems
>> to kill all newlines inside the text so that all the preformatted code is
>> squished into a single line. Is there any way to change this?
>
> Does it kill the newlines after you press submit, but only in the
> resulting text? Put another way, when you go back to edit it, are the
> lines still there? If so, you will need to look at line break
> conversion in your input formats.
>
> Click admin -> input formats
> Click configure next to the input formats you have enabled
> Select "line break converter" for each input format.
Sorry to say, but it doesn't work either with or without the line break
converter. If I switch to source mode inside the FCKEditor, I can see that
<br/>-Tags are present inside the <pre>formatted text, and they stay there
even when trying to re-edit the page. However, in the displayed page, the
breaks were gone.
By disabling all filters and re-enabling them one by one, I was able to track
the problem down to the HTML filter. As soon as I disable this filter,
everything works just fine. If it's enabled - no line breaks. Whether I tell
the filter to allow <br> and even <br/> doesn't matter :-(
Where to go from here? Is this behaviour intended or is it a bug?
Volker
--
* Volker Wegert * http://www.volker-wegert.de/contact *
* "Die Geduld nicht verlieren, auch wenn es unmöglich scheint, das ist
* Geduld." (aus Japan)
*
More information about the drupal-support
mailing list