Code Macro's parameter case sensitivity is causing issues.

XMLWordPrintable

      Description

      This issue seems to affect all Confluence 3.5 and above (New code macro plugin is implemented). Users upgrading from Confluence prior to 3.5 with code macro parameters that have a mixture of uppercase letters will encounter the following error:

      code: Invalid value specified for parameter lang

      How to Reproduce

      1. Create a page in Confluence 3.5
      2. Key in {code: None} example {code} under Wiki Markup
      3. Save the page
      4. You will see the following error message displayed:
      5. Try to edit the page again, if you go over to the Wiki Markup tab, notice that the contents inside the code macro is missing:

      Workaround

      Option 1) Disabling the New Code Macro and install the older Code Macro

      1. Go to Confluence Admin >> Plugins >> Code Macro Plugin >> Disable Code Macro Plugin
      2. Download the attached confluence-code-macro-1.5.jar (Old code macro)
      3. Install this plugin via Confluence Admin >> Plugins >> Install >> Upload Plugin

      Option 2) Database search and replace

      The following query works on MySQL:

       UPDATE `bodycontent` set body = replace(body, '{code:None}', '{code:none}') 

      After performing the query, go to Confluence Admin >> Cache Statistics >> Click on Flush All. The problem should be fixed now.

        1. codemacro3.jpg
          codemacro3.jpg
          42 kB
        2. codemacro2.jpg
          codemacro2.jpg
          27 kB
        3. codemacro.jpg
          codemacro.jpg
          21 kB

            Assignee:
            KaiA
            Reporter:
            Foo Sim (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: