Recompile templates and phrases of XenForo

Thảo luận trong 'Development Tutorials' bắt đầu bởi thanhmu, 10/5/12.

1votes
5/5, 1 vote

  1. thanhmu

    thanhmu Member

    Bài viết:
    3
    Likes :
    1
    The following code snippet will "force" to recompile all templates and phrases

    For phrases (change languageId to yours)
    Mã:
    $p = new XenForo_Model_Phrase();
    $p->compileAllPhrasesInLanguage(1);
    For templates
    Mã:
    $t = new XenForo_Model_Template();
    $t->compileAllTemplates();
    If you just need to run it for whatever reason you could add it in index.php just before fc->run()
     
    Đang tải...
  2. Xavier

    Xavier Well-Known Member

    Bài viết:
    1,414
    Likes :
    522
    cho xin cái ảnh demo
     
comments powered by Disqus

Chia sẻ trang này

Đang tải...