<!-- ######################################################### -->

//Popup Box- By Jim Silver @ jimsilver47@yahoo.com
//Exlusive permission granted to Dynamic Drive (http://dynamicdrive.com) to include this script in their DHTML archive.
//For full source code, terms of use, and 100's more scripts, visit http://www.dynamicdrive.com

var ns4=document.layers
var ie4=document.all
var ns6=document.getElementById&&!document.all

//drag drop function for NS 4////
/////////////////////////////////

var dragswitch=0
var nsx
var nsy
var nstemp

function drag_dropns(name){
if (!ns4)
return
temp=eval(name)
temp.captureEvents(Event.MOUSEDOWN | Event.MOUSEUP)
temp.onmousedown=gons
temp.onmousemove=dragns
temp.onmouseup=stopns
}

function gons(e){
temp.captureEvents(Event.MOUSEMOVE)
nsx=e.x
nsy=e.y
}
function dragns(e){
if (dragswitch==1){
temp.moveBy(e.x-nsx,e.y-nsy)
return false
}
}

function stopns(){
temp.releaseEvents(Event.MOUSEMOVE)
}

//drag drop function for ie4+ and NS6////
/////////////////////////////////



function initializedrag(e){
crossobj=ns6? document.getElementById("showimage") : document.all.showimage

var firedobj=ns6? e.target : event.srcElement
var topelement=ns6? "HTML" : "BODY"


}
document.onmousedown=initializedrag
document.onmouseup=new Function("dragapproved=false")

////drag drop functions end here//////

var id=0;

function waithidebox(){
clearTimeout(id);
id=setTimeout(hidebox,3000);
}
function hidebox(){
showselect('L1','L2')
if (ie4||ns6) {
 if( crossobj ) {
  crossobj.style.visibility="hidden"
 }
} else if (ns4) {
//document.showimage.visibility="hide"
}
}

function nothide(){
clearTimeout(id);
}

function showbox(){
clearTimeout(id);
if (ie4||ns6)
{
 if( crossobj ) {
  crossobj.style.left=(document.body.clientWidth -760)/2+(760-280);
  crossobj.style.visibility="visible"
 }
}
else if (ns4)
{
//document.showimage.left=(window.innerWidth-760)/2+(760-280);
//document.showimage.visibility="visible"
//document.showimage.zIndex=100
}
loadChibicartInner()
}

function resize(){
if (ie4||ns6)
{
 if( crossobj ) {
  crossobj.style.left=(document.body.clientWidth -760)/2+(760-280);
 }
}
else if (ns4)
{
 if( crossobj ) {
  // crossobj.style.left=(window.innerWidth-760)/2+(760-280);
 }
}
}

function hideselect(id1,id2) {
  if( document.all && document.all.item(id1) ) {
    document.all.item(id1).style.visibility = "hidden";
  }
  if( document.layers && document.layers[id1] ) {
    document.layers[id1].visibility = "hide";
  }
  if( document.all && document.all.item(id2) ) {
    document.all.item(id2).style.visibility = "hidden";
  }
  if( document.layers && document.layers[id2] ) {
    document.layers[id2].visibility = "hide";
  }
}
function showselect(id1,id2) {
  if( document.all && document.all.item(id1) ) {
    document.all.item(id1).style.visibility = "visible";
  }
  if( document.layers && document.layers[id1] ) {
    document.layers[id1].visibility = "show";
  }
  if( document.all && document.all.item(id2) ) {
    document.all.item(id2).style.visibility = "visible";
  }
  if( document.layers && document.layers[id2] ) {
    document.layers[id2].visibility = "show";
  }
}
var ie=document.all&&navigator.userAgent.indexOf("Opera")==-1
var dom=document.getElementById&&navigator.userAgent.indexOf("Opera")==-1
function loadChibicartInner(){
if (ie||dom){
var iframeobj=document.getElementById? document.getElementById("chibicartinner") : document.all.chibicartinner
iframeobj.src="blank.html"
iframeobj.src="/enjoy/chibicartInner.jsp"
}
}
function parentUrl(url){
 window.location.href=url
}
<!-- ######################################################### -->

