• Resolved tbthierry

    (@tbthierry)


    Hello,

    I checked everywhere and I do not understand what should I do?
    wp_icl_languages ​​the table does not exist in my database and this causes errors on ovh each opening page.
    Can you advise me?
    thank you

    [error]
    PHP message: WordPress database error Table ‘****.wp_icl_languages’ doesn’t exist for query select default_locale from wp_icl_languages where code = ‘en’ made by require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/themes/theme21/page.php’), get_template_part, locate_template, load_template, require(‘/themes/theme21/content-page.php’), theme_get_content, the_content, apply_filters(‘the_content’), call_user_func_array, really_simple_share_content, really_simple_share, really_simple_share_adjust_locale, referer: http://www.gite-lareunion.com/home/

    and I read in comment on wpml-compat.php:
    /*
    * defines two WPML constants once the language has been defined
    * the compatibility with WPML is not perfect on admin side as the constants are defined
    * in ‘setup_theme’ by Polylang (based on user info) and ‘plugins_loaded’ by WPML (based on cookie)
    * moreover I believe that WPML can set ICL_LANGUAGE_CODE to ‘all’ which I dont want to do with Polylang
    *
    * @since 0.9.5
    */

    https://ww.wp.xz.cn/plugins/polylang/

Viewing 13 replies - 1 through 13 (of 13 total)
  • Plugin Author Chouby

    (@chouby)

    There is a plugin or your theme which believes that WPML is installed on your website and want to play with internal tables of WPML. Polylang provides the public API of WPML so that several themes and plugins are compatible with both WPML and Polylang. But Polylang does not use any extra table. So obviously ‘wp_icl_languages’ can’t be found in your DB.

    Thread Starter tbthierry

    (@tbthierry)

    Hello and thank you Chouby for your plugin,

    I am new to the world of WP and I do not know much in database. I am a beginner.
    Basically, you tell me that are not your plugin “Polylang” I installed making the request to the database?
    PS: If Polylang is disabled, I have no error on OVH reassembled.
    Thank you for your help 😉
    Thierry

    Plugin Author Chouby

    (@chouby)

    According to the error message, this is your theme which makes the request. But your theme believes that Polylang is WPML certainly because it tests for something present in both plugins (the theme author is unaware that Polylang mimics certain parts of WPML). After this test, the theme acts as if WPML is activated and is confident that it can find the internal tables of WPML, but of course it can’t find them since Polylang does not provide these tables.

    Thread Starter tbthierry

    (@tbthierry)

    Thank you,
    I am looking for over 1 hour, but I did not find what I need to change my theme made ​​by Artisteer.
    On the forum, it was said there that a few years Artisteer theme not working with Polylang plugin.
    http://www.artisteer.com/Default.aspx?post_id=182928&p=forum_post

    I’m still looking … If you have an idea of what I should try, let me know;-)
    Thierry

    Thread Starter tbthierry

    (@tbthierry)

    I just discovered that there was a debug mode in WP!
    Here is the result:
    Notice: Undefined property: theme_MenuItem::$classes in ***/polylang/frontend/frontend-nav-menu.php on line 96

    the same on line 100 and on line 107.

    And WordPress database error: [Table ‘***.wp_icl_languages’ doesn’t exist]
    select default_locale from wp_icl_languages where code = ‘fr’

    code of frontend-nav-menu:
    /** removes current-menu and current-menu-ancestor classes to lang switcher when not on the home page
    * @since 1.1.1
    * @param array $items
    * @return array modified menu items*/
    public function wp_nav_menu_objects($items) {
    $r_ids = $k_ids = array();

    foreach ($items as $item) {
    line96 if (is_array($item->classes) && in_array(‘current-lang’, $item->classes)) {
    $item->classes = array_diff($item->classes, array(‘current-menu-item’));
    $r_ids = array_merge($r_ids, $this->get_ancestors($item)); // remove the classes for these ancestors
    }
    ligne100 elseif (is_array($item->classes) && in_array(‘current-menu-item’, $item->classes))
    $k_ids = array_merge($k_ids, $this->get_ancestors($item)); // keep the classes for these ancestors
    }

    $r_ids = array_diff($r_ids, $k_ids);

    foreach ($items as $item) {
    ligne107 if (in_array($item->db_id, $r_ids))
    $item->classes = array_diff($item->classes, array(‘current-menu-ancestor’, ‘current-menu-parent’, ‘current_page_parent’, ‘current_page_ancestor’));
    }

    return $items;
    }

    ! good night !

    Plugin Author Chouby

    (@chouby)

    These are two different issues. The menu issue is a conflict between Polylang and Artisteer. I believe that you can’t add the language switcher to the menu with Artisteer themes. So you should try the widget instead.

    For the database issue, you should try to switch to another theme (twenty twelve for example) to be sure that it comes from Artisteer, or disable all other plugins to check if the conflict comes from another plugin.

    In any case, you should be able to disable the WPML compatibility mode by setting the PLL_WPML_COMPAT option to false: see http://polylang.wordpress.com/documentation/documentation-for-developers/list-of-options-which-can-be-set-in-wp-config-php/

    Thread Starter tbthierry

    (@tbthierry)

    YESSSS !!! Thanks Chouby, after modification of wp-config.php with define(PLL_WPML_COMPAT, false); error of wp_icl_languages ​​table disappears.

    Regarding the conflict between Polylang and the Artisteer menu.
    I just tested the language selector menu then in the “list of languages​​” widget and “Custom Menu” but it does not change the message “Undefined property”
    Would you have other good ideas?
    Thierry
    https://dl.dropboxusercontent.com/u/96725859/widget_polylang.jpg

    Plugin Author Chouby

    (@chouby)

    Does your “menu anglais” include a language switcher?

    Thread Starter tbthierry

    (@tbthierry)

    The configuration of the menus:
    https://dl.dropboxusercontent.com/u/96725859/menu.JPG

    I can add a link of “language switcher” (/#pll_switcher if I disable polylang) in “menu anglais” but we have the same warning “Undefined property”.

    Plugin Author Chouby

    (@chouby)

    Could you check if PHP notices are still there with the current development version (1.4.1.3)?
    http://downloads.wp.xz.cn/plugin/polylang.zip

    Thread Starter tbthierry

    (@tbthierry)

    Hello Chouby, I just test it and:
    with old version:
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 96
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 100
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107
    Notice: Undefined property: theme_MenuItem::$classes in *****/polylang/frontend/frontend-nav-menu.php on line 107

    and with 1.4.1.3:
    only x14 same lines:
    Notice: Undefined property: theme_MenuItem::$db_id in ***/polylang/frontend/frontend-nav-menu.php on line 110

    code:
    foreach ($items as $item) {
    line110: if (in_array($item->db_id, $r_ids))
    $item->classes = array_diff($item->classes, array(‘current-menu-ancestor’, ‘current-menu-parent’, ‘current_page_parent’, ‘current_page_ancestor’));
    }

    Plugin Author Chouby

    (@chouby)

    OK not only $classes but also $db_id is not defined in Artisteer themes 🙁
    The latest dev version (1.4.1.4) should fix that.

    Thread Starter tbthierry

    (@tbthierry)

    Thank you Chouby, Frederic,

    Everything now works without error or Warning.
    Your plugin is simple with good and fast support. I recommend it!
    Thank you for having solved incompatibility with Artisteer theme.
    I can sleep on my ears tonight 😉

    Good evening and good continuity.
    Thierry (http://www.gite-lareunion.com)

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

The topic ‘table wp_icl_languages doesn t exist’ is closed to new replies.