• please for the love of all things furry help me out.
    Ive been googling and searching all over but can not get it to work

    I am trying to set up a site with 2 languages en and cz I have installed the plugin fine, I can even make posts. But I can not make a menu bar that changes languge when selected. I am gathering it is because I have a fixed menu or something and I can find the bit of code in php but what ever I change just dont work. I got that peeved of I just deleted the site and now starting again.

    Please help
    Thanks

Viewing 14 replies - 1 through 14 (of 14 total)
  • Thread Starter steveibo

    (@steveibo)

    oh to add to this I am using the photo grid theme by http://www.dessign.net/

    and the code I have found in the header is this

    <?php wp_nav_menu('menu=header_menu&container=false&menu_id=menu'); ?>

    Written like this, your theme will load the menu ‘header_menu’ if exists (and there is probably no reason why users should name their menu this way) or always loads the first created menu. That is probably what happens to you.

    There is no other way than modifying your theme and, as always, the best is to take default themes as example.

    In your file functions.php, add this line (for example just after the first line <?php):
    register_nav_menu( 'primary', 'Header menu' );
    And modify the line of code above in:
    <?php wp_nav_menu('theme_location=primary&container=false&menu_id=menu'); ?>

    Thread Starter steveibo

    (@steveibo)

    thanks, I have a new problem now, that seemed to work I added the first bit of code to the functions.pho in side the theme folder is that right??

    Because now if I click on my languages I can not change them back to english.

    Here is my site http://www.stevenibinson.com
    Thank you so much for this.

    Did you write at least one post in echa language?
    See also: http://wordpress.org/support/topic/polylang-homepage-shows-posts-in-both-languages

    Thread Starter steveibo

    (@steveibo)

    will do a fresh install again in the morning. I did everything I belive but when I click home button it gives me all types of errors. Will get back to you in the morning. Thanks again for all the help.

    Thread Starter steveibo

    (@steveibo)

    right done a fresh install at stevenibinson.com

    Followed everything including the link above which sorted out double posting awesome thanks.
    Problem I have now is I can make the english and czech blog work together. When I post to the blog in english it shows up as english on the czech side aswell. So I edit it for the czech side and it just goes to the featured home page and not the blog????

    any ideas.
    And once again, thank you so much for the help.

    Please update to the development version of Polylang 1.1. It should help as this new version includes a new feature to translate the categories queried by themes.
    http://downloads.wordpress.org/plugin/polylang.zip

    Then translate the category ‘blog’ in the other language and use the right category in the right language when you create a new blog post.

    Thread Starter steveibo

    (@steveibo)

    Hi i have updated it, but the menu option in the admin area has now disapeared???

    Thread Starter steveibo

    (@steveibo)

    plus every time I make a new page I get all type of php errors. it still posts but well it dont like it.

    Hi i have updated it, but the menu option in the admin area has now disapeared???

    Yes, everything is now integrated in the menu section of WordPress (Appearance->menus)

    plus every time I make a new page I get all type of php errors. it still posts but well it dont like it.

    What are these errors? I get some notices when I activate your theme. But I am interested to know if errors are coming from Polylang.

    Thread Starter steveibo

    (@steveibo)

    this is the error I get when I try to publish a new page.

    Fatal error: Call to undefined method Polylang_Nav_Menu::get_post_language() in /home/kamibo55/public_html/stevenibinson.com/wp-content/plugins/polylang/include/nav-menu.php on line 164

    Thread Starter steveibo

    (@steveibo)

    because of this I am unable to actually post translated pages, it post the page but for some reason spits out that error and when I go back it puts it as a seperate page not a translated one.

    Thank you very much for your report. Could you replace the line by:

    if ('publish' != $new_status || 'publish' == $old_status || 'page' != $post->post_type || ! empty($post->post_parent) || !($lang = $GLOBALS['polylang']->get_post_language($post->ID)))

    Thread Starter steveibo

    (@steveibo)

    sorted thank you. hopefully thats it for now but will leave open untill tommorow whilst i set up the rest.
    Thank you!!!!!

Viewing 14 replies - 1 through 14 (of 14 total)

The topic ‘[Plugin: Polylang} Menu dramas’ is closed to new replies.