Home 게시판 커뮤니티 Q&A polyglot plugin 질문입니다.

2개 답변, 1 voice Last updated by Avatar of aeronovaaeronova 18 years, 1 month 전
  • Avatar of aeronovaaeronova
    Participant
    @aeronova
    #1119

    에고, 자답입니다.
    결국 polyglot의 저자의 블로그에서 문의 결과, 제가 plugin을 activate하지 않았다는 것을 알았습니다. :-// 저는 plugin에서 action이 activate라고 되어 있어서 그냥 activate되었는 줄 알았는데, 그게 아니었습니다. 간단히 activate를 클릭하는 것으로 모든 문제가 해결되었네요. 🙂

    Avatar of aeronovaaeronova
    Participant
    @aeronova
    #1120

    안녕하세요, polyglot을 설치하고 테스트 중인데 생각처럼 쉽게 되질 않습니다.
    우선은 제 default theme의 index.php의 맨 마지막에 다음 코드를 추가했구요,

    <?php if(function_exists('lp_other_langs')) {
    //display existing language versions of the post
    lp_other_langs(' ','<ul>', '</ul>', '<li>', '</li>');
    }?>

    그리고 polyglot.php에 일단 ‘en’과 ‘fr’을 다음처럼 추가했습니다.

    $polyglot_settings['default_lang'] = 'en';

    //You can define your own translations of language shortcuts
    $polyglot_settings['trans']['en'] = 'english';
    $polyglot_settings['trans']['fr'] = 'french';

    //Which language versions you offer for the whole web - use the proper ISO codes!
    $polyglot_settings['knownlangs'] = array('en', 'fr');

    //if there should be shown flags instead of names of languages
    $polyglot_settings['use_flags'] = true;

    //list of ISO codes and their image represantations (flags).
    //all flags can be found in 'polyglot_flags' directory
    $polyglot_settings['flags']['en'] = 'us.png';
    $polyglot_settings['flags']['fr'] = 'fr.png';

    //time format for each language
    //if not set - default WP time format is used
    $polyglot_settings['time_format']['en'] = 'g.i a';
    $polyglot_settings['time_format']['fr'] = 'g.i a';

    $polyglot_settings['date_format']['en'] = 'Y-m-d';
    $polyglot_settings['date_format']['fr'] = 'Y-m-d';

    그런 후 테스트 용으로 다음처럼 포스팅했구요.

    <p><lang_en>Written in English…</lang_en><br />
    <lang_fr>Written in French…</lang_fr></p>

    하지만 http://home.pusan.ac.kr/~aeronova/blog에서 보시듯이 두 언어가 선택적으로 나오질 않습니다.ㅜㅜ

    음… php에 문외한이라 어떻게 문제를 해결해야 할 지 모르겠습니다. 도움 부탁드립니다.

    Avatar of aeronovaaeronova
    Participant
    @aeronova
    #1121

    안녕하세요, polyglot을 설치하고 테스트 중인데 생각처럼 쉽게 되질 않습니다.
    우선은 제 default theme의 index.php의 맨 마지막에 다음 코드를 추가했구요,

    <?php if(function_exists('lp_other_langs')) {
    //display existing language versions of the post
    lp_other_langs(' ','<ul>', '</ul>', '<li>', '</li>');
    }?>

    그리고 polyglot.php에 일단 ‘en’과 ‘fr’을 다음처럼 추가했습니다.

    $polyglot_settings['default_lang'] = 'en';

    //You can define your own translations of language shortcuts
    $polyglot_settings['trans']['en'] = 'english';
    $polyglot_settings['trans']['fr'] = 'french';

    //Which language versions you offer for the whole web - use the proper ISO codes!
    $polyglot_settings['knownlangs'] = array('en', 'fr');

    //if there should be shown flags instead of names of languages
    $polyglot_settings['use_flags'] = true;

    //list of ISO codes and their image represantations (flags).
    //all flags can be found in 'polyglot_flags' directory
    $polyglot_settings['flags']['en'] = 'us.png';
    $polyglot_settings['flags']['fr'] = 'fr.png';

    //time format for each language
    //if not set - default WP time format is used
    $polyglot_settings['time_format']['en'] = 'g.i a';
    $polyglot_settings['time_format']['fr'] = 'g.i a';

    $polyglot_settings['date_format']['en'] = 'Y-m-d';
    $polyglot_settings['date_format']['fr'] = 'Y-m-d';

    그런 후 테스트 용으로 다음처럼 포스팅했구요.

    <p><lang_en>Written in English…</lang_en><br />
    <lang_fr>Written in French…</lang_fr></p>

    하지만 http://home.pusan.ac.kr/~aeronova/blog에서 보시듯이 두 언어가 선택적으로 나오질 않습니다.ㅜㅜ

    음… php에 문외한이라 어떻게 문제를 해결해야 할 지 모르겠습니다. 도움 부탁드립니다.

3 글 보임 - 1에서 3 까지 (총 3 중에서)
  • 답변은 로그인 후 가능합니다.