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

Replacing All Instances of a User Name

Discussion in 'XenForo Development Discussions' started by James, Aug 5, 2011.

  1. James

    James Well-Known Member

    I originally thought replacing all instances of a user name would be as simple as just overriding the userNameHtml function - however that doesn't suffice.

    When overriding the userNameHtml function, it doesn't replace all instances of a user name. How would I go about replacing all instances?

    By all instances I don't mean text in quotes etc, just things such as thread username, member card, etc.
  2. Blue

    Blue Well-Known Member

    Is this an ex user? If so you could try the word censor.
  3. James

    James Well-Known Member

    It's for an add-on.
  4. James

    James Well-Known Member

    Just to add, I've overwritten the {xen:helper username} which replaces areas such as the user block and the thread listing (when the thread is soft deleted). I'll need template edits to override the {$user.username} or {$username} - I just need to work out how to override the XenForo_Template_Compiler_Tag_Username::compile() function.

Share This Page