function chlocation(){
var current=document.URL;
if (current.indexOf("#")!=-1) //test for "#" in the URL, if not present, skip next line
	current = current.substring(current.lastIndexOf("#"), 0);
var mykey=((current).split("/"))[((current).split("/")).length-1];
var mykey1=((mykey).split("\\"))[((mykey).split("\\")).length-1];
var fname = mykey1.substring(mykey1.lastIndexOf("."),0);
p=fname;
window.location.href = 'index.html?'+fname;
}

function loadok() {
if (parent.location.href != self.location.href || parent.correct_frame){
parent.loadok();
}
else {
setTimeout("chlocation()", 150);
}}