Support » Plugins » qtranslate home link – yootheme

  • If people choose between my languages (English or German) and then click the Home-button, they always come to a German site (default). I’m using a Yootheme template.

    Unfortunately, my functions.php file calls my config.php file which is in turn calls 4 other files. So I am also not sure how to solve this problem.

    functions.php:
    // load config
    require_once(dirname(__FILE__).’/config.php’);

    config.php:
    require_once(dirname(__FILE__).’/warp/warp.php’);

    $warp =& Warp::getInstance();

    // add paths
    $warp->path->register(dirname(__FILE__).’/warp/systems/wordpress.3.0/helpers’,’helpers’);
    $warp->path->register(dirname(__FILE__).’/warp/systems/wordpress.3.0/layouts’,’layouts’);
    $warp->path->register(dirname(__FILE__).’/layouts’,’layouts’);

    $warp->path->register(dirname(__FILE__).’/js’, ‘js’);
    $warp->path->register(dirname(__FILE__).’/css’, ‘css’);

    // load helpers
    $warp->loadHelper(array(‘system’, ‘modules’, ‘javascripts’, ‘stylesheets’, ‘useragent’, ‘cache’));

    require_once(dirname(__FILE__).”/presets.php”);

    I have found a system.php file within the template under /warp/systems/wordpress.3.0/helpers’ which has the following:

    system.php:
    // parse site url
    $urlinfo = parse_url(get_option(‘siteurl’));
    $url = $urlinfo[‘path’];

    Not sure if this is the right place to get the link going right.

    What is strange is that when I run my mouse of the header banner it shows the correct language url i.e. …/en/…, but when I click it it jumps back to the default language. Home button shows the url without language tag …/en/… and also jumps back to the default language.

    Anyone with ideas??? ❓

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi, I have the same problem and wanted to know if you found a solution in the meantime?

    Greetings,

    Sebastian.

    Try using items_wrap parameter to wp_nav_menu, in this way:

    <?php wp_nav_menu( array('items_wrap' => '<ul id="%1$s" class="%2$s"><li><a href="'.get_bloginfo('home').'">Home</a></li>%3$s</ul>' ) ); ?>

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘qtranslate home link – yootheme’ is closed to new replies.