<?

//Get the full string in the url including variables
$CurrentURIplusQS = $_SERVER['REQUEST_URI'];

//echo($CurrentURIplusQS);

//take out the current language settings completely for the purposes of generating these links
$newURIplusQS = str_replace("L=10", "", $CurrentURIplusQS);
$newURIplusQS2 = str_replace("L=0", "", $newURIplusQS);


//print the links with the language vars removed so we can start again by adding the QS each time
echo '<a href="'.$newURIplusQS2.'?&L=0">English</a> | <a href="'.$newURIplusQS2.'?&L=10">Bahasa</a>';

?>