var setIntervalId=null;
var i= 0;
function move_layer(layer){

document.getElementById(layer).style.left=i;
i=i+5;
//document.getElementById(layer).innerHTML+=i;
if (i>500){ i =0};
document.ondrag=function (){alert("ok");}
}

function trigger(layer){

setIntervalId=setInterval("move_layer('Shopping_Basket')",100);

}
//to move the layer with the mouser movement in the documnet
//window.onscroll=function () {document.getElementById('Shopping_Basket').style.top=document.body.scrollTop;
// to show th tooltip of the links on the page
//load a layer first

function show_Tooltip(textToDisplay,tevent){
tool_tip=document.getElementById('tooltip');
tool_tip.innerHTML=textToDisplay;
tool_tip.style.left=tevent.clientX+5;
tool_tip.style.top=tevent.clientY+5;
tool_tip.style.visibility="visible";


}

function hide_Tooltip(){
tool_tip=document.getElementById('tooltip');
tool_tip.style.visibility="hidden";
}
function change(spanid)
{//document.getElementById(spanid).innerHTML="";
docx=document.getElementById(spanid);
docx.style.display= (docx.style.display == "none") ? "block" :
"none";

//document.getElementById(i+1).getElementById.innerHtml=null

}

function move_layer(gotevent)
{document.getElementById("panel").style.left=gotevent.clientX;
document.getElementById("panel").style.top=gotevent.clientY+10;

}


// for the tooltip
function show_Tooltip(textToDisplay,tevent){
tool_tip=document.getElementById('tooltip');
tool_tip.innerHTML=textToDisplay;
//doesn't work on ie why idon't know i am working on it

tool_tip.style.left=tevent.clientX + document.body.scrollLeft + 5;//incase of the scrolling lock use this okey
tool_tip.style.top=tevent.clientY+ document.body.scrollTop + 5;//in ie don't use window.clientX or y this document.body.scrollTop works on both ie and firefox
tool_tip.style.visibility="visible";


}

function hide_Tooltip(){
tool_tip=document.getElementById('tooltip');
tool_tip.style.visibility="hidden";
}

