var which_page ="";
var leaving=true; 
var need_under=false;
var no_more=false;


if (document.cookie) { 

        // load the cookie into a variable and unescape it
	var the_cookie = document.cookie;

        // var the_cookie = unescape(the_cookie);
        // I dont unescape the cookie because the cookie contains a search engine URL with special charecters in it that I need.

	// separate the values from the cookie name
        // PHP seperates the cookies with a semicolon - ;
	var split_pairs = the_cookie.split(";");

        var name_value_pair = "";

             for (var loop = 0; loop < split_pairs.length; loop++)
             {
             name_value_pair = split_pairs[loop];
             var final_values = name_value_pair.split("=");
             var name = final_values[0];
             var the_value = final_values[1];
               if (the_value == 'seenit') { need_under = true; }
               if (the_value == 'seenit2') { no_more=true; }
             }

 
}


function popup2(url) { 
var win = window.open(url, "win", "width=475, height=450,left=50,scrollbars=yes,top=50"); 
win.focus();
}


var popWin = null    
var winCount = 0
var winName = "popWin" 
function openPopWin(winURL, winWidth, winHeight, winFeatures, winLeft, winTop){ 
  var d_winLeft = 20  
  var d_winTop = 20   
  winName = "popWin" + winCount++  
  closePopWin()           
  if (openPopWin.arguments.length >= 4)    
    winFeatures = "," + winFeatures 
  else  
    winFeatures = ""  
  if (openPopWin.arguments.length == 6)   
    winFeatures += getLocation(winWidth, winHeight, winLeft, winTop) 
  else 
    winFeatures += getLocation(winWidth, winHeight, d_winLeft, d_winTop) 
  popWin = window.open(winURL, winName, "width=" + winWidth  
           + ",height=" + winHeight + winFeatures) 
  } 
function closePopWin(){     
  if (navigator.appName != "Microsoft Internet Explorer"  
      || parseInt(navigator.appVersion) >=4)  
    if(popWin != null) if(!popWin.closed) popWin.close()  
  } 
function getLocation(winWidth, winHeight, winLeft, winTop){ 
  return "" 
  }


function now()
{
alert(temp[0]);
document.thepic.src=picture
}

function popwindow(url) {
  demote = open(url, "Popwindow", "width=675,height=375,left=50,top=50,leftmargin=60,margintop=0,margin-top=0,topmargin=0,rightmargin=0,bottommargin=0");
}

function openindex(which_page)
{



}