hi.... im using this code, i took it from one of the templates i think, so im not sure if its correct, but the weird thing is, that i have made another mulitlingual website, just the same way, and it works fine?

but im might be missing something?
------------------------------------------------------------------------------
<div id="mainmenu" align="center" valign="middle">
<ul>
<?php
// Get language page link
$parse_wb_url = parse_url(WB_URL);
$set = $parse_wb_url['path'];
$actual = $_SERVER['REQUEST_URI'];
$pageslen = strlen(PAGES_DIRECTORY);
$language_link = substr(str_replace($set, '', $actual), $pageslen, 3);
// Get language page id
$result = $database->query("SELECT page_id FROM ".TABLE_PREFIX."pages WHERE link = '$language_link' LIMIT 0,1");
if($result->numRows() > 0) {
$page = $result->fetchRow();
page_menu($page['page_id']);
} else {
// Can't figure out the root ID, so just use normal menu
page_menu(0);
}
?>
</ul>
</div>
---------------------------------------------------------------------