Skip to:
Content
Pages
Categories
Search
Top
Bottom

Displaying XSL / XML syntax sample code

  • @ajtruckle

    Participant

    This is a nightmare from what i can see unless you use the TEXT editor and the CODE tag ONLY.

    If I insert some sample XSL script into CODE blocks. Example:

    <xsl:choose>
      <xsl:when test="@ItemPosition='1' and Assistant!=''">
        <xsl:text><span style="background-color: #ffff00;">1st:</span> </xsl:text>
      </xsl:when>
      <xsl:when test="@ItemPosition='2'">
        <xsl:text><span style="background-color: #ffff00;">2nd:</span> </xsl:text>
      </xsl:when>
      <xsl:when test="@ItemPosition='3'">
          <xsl:text><span style="background-color: #ffff00;">3rd:</span> </xsl:text>
      </xsl:when>
    </xsl:choose>

    I can edit it to my hearts content. But if I use the TinyMCE edit to edit this post (with the TinYMCE editor being the default at the moment I edit) it strips all the XSL syntax.

    Now, I realise that I can add a load of XSL tags into my custom functions.php class to permit these syntax words but that will be a nightmare. XSL has a lot of syntax. Is there really no standard (TinyMCE compatible) where we can insert code snippets and they look correct to the user and still be editable afterwards in either editor?

Viewing 4 replies - 1 through 4 (of 4 total)
  • @robin-w

    Moderator

    how are you adding tinymce to bbpress ?

    @ajtruckle

    Participant

    TinyMCE Advanced plug-in since it allows more configuration of the buttons on the toolbar.

    @robin-w

    Moderator

    so if you have added them in bbp_kses_allowed_tags, then it is may be a TinyMCE Advanced plug-in issue

    @ajtruckle

    Participant

    At the moment I have not added them to the allowed tags. It is just that xsl scripting is a huge concept and I really don’t want to have to add all possible configurations there. The TinyMCE Advanced say it is not their issue (like the video / source escape issue).

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.
Skip to toolbar