function setCookie1(name, value, expires) 
{
	var expireDate = expires.toGMTString();
	document.cookie = name+"="+escape(value)+"; path=/; expires="+expireDate;
}
function getCookie(name) 
{
  var result = null;
  var myCookie = " " + document.cookie + ";";
  var searchName = " " + name + "=";
  var startOfCookie = myCookie.indexOf(searchName);
  var endOfCookie;
  if (startOfCookie != -1) {
    startOfCookie += searchName.length; // skip past cookie name
    endOfCookie = myCookie.indexOf(";", startOfCookie);
    result = unescape(myCookie.substring(startOfCookie, endOfCookie));
  }
  return result;
}
function deleteCookie(name) 
{
	var expireDate = "Thu, 01-Jan-70 00:00:01 GMT";
	document.cookie = name+"=; path=/; expires=Thu, 01-Jan-70 00:00:01 GMT";
}
function itpopups()
{	
	var exp = new Date();
	exp.setTime(exp.getTime() + (60 * 60 * 1000));
	setCookie1("itpopups","yes",exp);
}
function adpopup(val)
{	
	var v = val;
	var exp = new Date();
	exp.setTime(exp.getTime() + (60 * 60 * 1000));
	setCookie1("itadpopup",v,exp);
}
function picdetailwin(url, winname)
{
	window.open(url, winname, "toolbar=no,status=no,resizable=yes,scrollbars=yes,location=no,menubar=no,directories=no,width=800,height=600");
}
function emailpic(url, winname)
{
	window.open(url, winname, "toolbar=no,status=no,resizable=no,scrollbars=yes,location=no,menubar=no,directories=no,width=300,height=400");
}

function shp()
{
 	if(document.all)
 	{   
 		document.body.style.behavior='url(#default#homepage)';   
		document.body.setHomePage('http://www.indiatarget.com/index.shtml');  
	}  
	else
	{   
		alert('This function is only supported by Internet Explorer,   please set your home page to this site manually.');  
	}
}
