Skip to:

Conflict with qTranslate

  • barnabe


    Hi all,

    I try to make a multilingual website with WordPress and I have a bug (?) when I activate bbPress and qTranslate both.
    Indeed, the bbPress’ menu in admin appears correctly when qTranslate is disabled, but disappears when both are activated. And if I try to go to the edit topic’s page, WordPress says to me I don’t have rights. I debug the allcaps WP_User property and I don’t find the edit_topics capability.

    How can I fix that problem?

    Subsidiary question: Does bbPress allow multilingual?

    My config :

    – WordPress 3.8.1 (last)
    – bbPress 2.5.3 (last)
    – qTranslate 2.5.39 (last)


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

  • John James Jacoby


    Sounds to be like qTranslate is accidentally stomping out bbPress’s top level menu locations. WordPress’s code in regards to navigation has a tendency to be pretty fickle in this regard.

    bbPress even takes measures to try and avoid this from happening on its own, but it looks like it’s still not enough anymore.

    We’ll see if there’s anything we can do on our end to avoid any of these kinds of menu collisions again. If so, improvements will come in a future version of bbPress.




    Thanks for the answer! In fact, this is no a display problem in admin menu, but rights (user capabilities). When I set the URL “edit.php?post_type=forum” directly in the addresses’ bar, WordPress says to me I have not the right to access this page.

    After a “very” long debug, I found why this behavior appends. The qTranslate plugin is loaded before bbPress and sets up the WP_User via the function wp_get_current_user() and so sets its allcaps. So when WordPress object is init in wp-settings.php file to sets up current user, wp_get_current_user() returns the existing user and not reloads capabilities.

    I fixed this problem in adding a param to wp_get_current_user():

    function wp_get_current_user($new_user = false){}

    and the same param to get_currentuserinfo() and wp_set_current_user(). I also modified the condition in get_currentuserinfo():

    if ( ! empty( $current_user ) && $new_user === false ) {

    and the condition in wp_set_current_user():

    if ( isset( $current_user ) && ( $current_user instanceof WP_User ) && ( $id == $current_user->ID ) && $new_user === false )

    Then I added the true value in param to the call of wp_get_current_user() in init method of WP class.

    Maybe this bug appears because I installed qTranslate before bbPress. Maybe this bug not appears if bbPress is installed before qTranslate. I’ll try an another install to test that. It would be nice not to change the core of WordPress.



    Maybe this bug not appears if bbPress is installed before qTranslate. I’ll try an another install to test that.

    Finally, even if bbPress is intalled before qTranslate, qTranslate is loaded first.



    Just chiming in here to follow this. I’m having the exact same problem.



    I have the same issue.

    To solve this i have implemented the fix of barnabe in small plugin. This way I don’t have to edit the core of WordPress.

    The plugin is available here:



    Thanks for the plugin exploder and to you as well barnabe. It worked perfectly. You two just became my best friends.



    Many many thanks to barnabe and exploder.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.
Skip to toolbar