1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Not a Bug Improper Title Case

Discussion in 'Resolved Bug Reports' started by Floren, Apr 21, 2014.

  1. Floren

    Floren Well-Known Member

    If you set the Title Case option in XenForo options, words containing the "-" character are malformed.
    If I'm not mistaken, all title sentences containing a - should be formatted Upper case.

    Example: Off-Topic, not Off-topic.
    Amaury likes this.
  2. Mike

    Mike XenForo Developer Staff Member

    The title case option is just an option that sets the first character in each word to upper case (using ucwords). There isn't any intention to go to any further detail.
  3. Floren

    Floren Well-Known Member

    That should do it @Mike:
    $ php -r 'var_dump(mb_convert_case("off-topic TITLE", MB_CASE_TITLE, "UTF-8"));'
    string(9) "Off-Topic Title"
    Thanks for implementing this.

Share This Page