Uploaded image for project: 'phpBB'
  1. phpBB
  2. PHPBB-12048

Custom BBCodes Fail to Render Language Strings with a Number

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 3.0.13-RC1
    • 3.0.12
    • Language pack
    • None

      The Custom BBCode creation page says

      "Within the HTML replacement you can also use any language string present in your language/ directory like this: {L_<STRINGNAME>} where <STRINGNAME> is the name of the translated string you want to add. For example, {L_WROTE} will be displayed as “wrote” or its translation according to user’s locale."

      This is not working for "any language string"! If there is an integer in the <STRINGNAME>, it will not be rendered, and instead outputs as {L_STRINGNAME}

      For example, create a simple custom BBCode.
      Use a common lang var in the HTML replacement code that has a number, i.e.: {L_1_DAY}
      That will render out in a post as {L_1_DAY}.

      Change that BBCode to use a lang var with no number in it, i.e.: {L_DAY}
      That will render as expected displaying the correct string value for the lang var, in this case, "Day"

            nickvergessen Joas Schilling
            VSE Matt Friedman [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: