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

How To Create A Phrase Pack?

Discussion in 'XenForo Questions and Support' started by DRE, Oct 2, 2012.

  1. DRE

    DRE Well-Known Member

    Hi. How do I create a phrase pack? I'm not changing the language, I just need to change a couple phrases.

    I want to attach the phrases to an addon I already made previously since someone complained about it not being 'phrased'.

    Also if I created an addon that is only phrase changes would it be the same method?
     
  2. Chris D

    Chris D XenForo Developer Staff Member

    When you create a phrase in the Master Language, you can choose the add-on they apply to. They then get exported with the add-on when you export its XML.
     
    Jake Bunce likes this.
  3. DRE

    DRE Well-Known Member

    Oh okay thanks! Instead of creating a new phrase, can't I take an existing phrase from the addon: Xenforo and assign it to my own?

    If I do this, will that phrase stay what I changed it to even after I upgrading xenforo or does xenforo overwrite or add the phrase again which then overrides your own?
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    Hmm, not sure that's a good idea as technically if your add-on is uninstalled it would remove the phrase completely rather than reverting it back to XenForo. That or you'd get a duplicate key error while trying to install the add-on, as technically the XML would be saying "create this phrase" and MySQL will say "I already have that. ERRROR".

    You can just reference default XenForo phrases in your templates e.g. {xen:phrase post_reply} but if you're actually changing the wording it might be better to create your own new phrase and reference that, e.g. {xen:phrase post_message}

    If this is how do you change existing XenForo phrases into something else, then actually I don't think you can.
     
  5. DRE

    DRE Well-Known Member

    Woops
     
  6. DRE

    DRE Well-Known Member

    Aww crap. How do I get the old phrases back?
     
  7. DRE

    DRE Well-Known Member

    Ah man..

    *goes back to sleep
     
  8. Chris D

    Chris D XenForo Developer Staff Member

    If you've edited the XenForo master phrase then I think you'd need to rebuild master data from /install

    G'night dude :LOL:
     
    8thos likes this.
  9. DRE

    DRE Well-Known Member

    This was done on my local installation so I'm not tripping. I'll just compare the phrases to my live test board http://xen-seo.com
     
  10. DRE

    DRE Well-Known Member

    lol this a big project.
     

Share This Page