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

XF 1.5 Something similar to Replacement Variables in vB

Discussion in 'XenForo Questions and Support' started by AliS, Jun 28, 2016.

  1. AliS

    AliS New Member

    Hello All,

    I was relying on Replacement Variables in vB to replace some letters in old and new messages.
    I have seen an add-on but I think it replaces only for old posts, not new ones (needs to run again).

    Any idea how to do this?

    Thank you.
  2. Chris D

    Chris D XenForo Developer Staff Member

    Do you have a specific example?

    It actually sounds like something that can be done using the censoring system but I'm not totally sure what your use case in.
  3. AliS

    AliS New Member

    Well, it something has to do with apple devices in the middle east.
    In the middle east we use Hindi numerals instead of Arabic numerals. (strange, right?!)
    I think apple differentiates between numerals in all languages. For example, if your password contains '1' in Hindi form, and you set it by an apple device, you will not be able to log in if you used the usual form '1'. This is not the case in Microsoft devices, where numerals are treated the same in the system.
    My problem is that if a user enters a number (from apple device) using Hindi form, it will be displayed as special chars. For example, if you entered the number '8' in the Hindi form (https://en.wikipedia.org/wiki/Eastern_Arabic_numerals if you are interested) it will show ظ¨ instead of ٨.

    Therefore Replacement Variables were useful.
    I hope it is clear.

    Thank you.
  4. AliS

    AliS New Member

    Chris D likes this.
  5. Chris D

    Chris D XenForo Developer Staff Member

    If I recall correctly, replacement variables in vBulletin were a bit more far reaching, I believe being applied before the final output of the page is displayed.

    The censor system in XF only applies to content within posts (conversations, profile posts - basically any user generated content), but if that's sufficient then it should be usable.

    Admin CP > Options > Censoring:


    (I appreciate that's not the exact example)

    But you get the idea. In this example any time 8 is used within a post, it is replaced with ٨.
    AliS likes this.
  6. Chris D

    Chris D XenForo Developer Staff Member

    AliS likes this.
  7. AliS

    AliS New Member

    @Chris D
    Has anyone ever told you that you are amazing?

    Thank you!
    Chris D likes this.

Share This Page