Review main Merged Breaking

51289[!!!][TASK] Remove RTE proc.transformBoldAndItalicTags option

Benni Mack CR +2 V +2 Normal +135 −29 updated 01/12/17, 20:43

Commit message

The option transformBoldAndItalicTags is there to convert
<i> and <b> tags from the DB to <strong> and <em> for the RTE.

When saving, all tags are converted back to <i> and <b>
before storing the content in the database again.

This is actually a (weird) shortcut due to historical reasons,
and can easily be set up by the HTMLparser directly using
the tags.[tagname].remap = [newtagname].

This syntax can be used directly to enable this functionality
again

RTE.default.proc {
        # make <strong> and <em> tags when sending to the RTE
    HTMLparser_rte {
            tags {
                b.remap = strong
                i.remap = em
            }
    }
        # make <b> and <i> tags when sending to the DB
    HTMLparser_db {
        tags {
            strong.remap = B
            em.remap = I
        }
    }
}

The option is removed and the explicit (and IMHO more understandable)
syntax is used in the RTE configuration of HTMLArea.

If the InlineElements functionality of HTMLarea is enabled,
then the remapping is not done, as any tag (b, i, strong, em)
is kept as is, becoming more flexible.

In any case, any "unification" if necessary, can also be
done the same way via the HTMLparser for the frontend
when outputting the content.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Files 4