Joe (erebrandir) wrote in lj_dev,
Joe
erebrandir
lj_dev

PATCH: lj-raw tag disables auto-formatting

Abstract

New lj-raw tag disables auto-formatting.

Description

As suggested by bradfitz, this patch provides a lj-raw tag, which disables auto-insertion of line breaks.

Example of usage:

<lj-raw>
  <H3>Stuff To Do</H3>
  <UL>
    <LI>Distribute LJ Virus</LI>
    <LI>Replace Brad with clone</LI>
    <LI>Take over LiveJournal</LI>
  </UL>
</lj-raw>

(The above code enclosed in lj-raw tags will not be auto-formatted, but
this
stuff
will.)

The lj-raw tag doesn't have to be closed; it'll work throughout your entry, comment, or bio.

Is there any reason why style attributes are stripped from the bio? Unsafe code is already being stripped from style attributes, so I don't see any reason for this. I've changed this in the patch.

Also includes some minor code cleanups, primarily converting tabs to spaces.

Patch

livejournal/cgi-bin/cleanhtml.pl Tested
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 9 comments