<!--
/*
 * Fly-in ads Creator 
 * 
 */
var NS = document.layers||navigator.userAgent.toLowerCase().indexOf("mac")!=-1;
var NS6 = (!document.all && document.getElementById)?true:false;
var message_text='<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\"> <html>  <head> <meta http-equiv=\"Content-Type\" content=\"text/html; charset=windows-1252\"> <title>Jokes and Quotes - Joke Genie Tells All.</title> </head>  <table id=\"table22\" style=\"border:3px dashed #0066CC; BORDER-COLLAPSE: collapse\" 																bordercolor=\"#000000\" cellspacing=\"0\" cellpadding=\"10\" width=\"100%\" border=\"1\"> <tbody> <tr><td bgcolor=\"#FFFFFF\"><p align=\"center\"><img border=\"0\" src=\"http://jokesandsayings.net/images/jokes-genie.gif\" width=\"72\" height=\"72\"><br></p><p align=\"left\"> <b><font face=\"Kristen ITC\" size=\"3\" color=\"#FF0000\">Join the Joke Genie\'s  "Jokes, Quotes, Funny Pictures and Other Goodies" Ezine.</b> <blockquote><p align=\"left\"><b><font face=\"Kristen ITC\" size=\"2\" color=\"#0000FF\">The Joke Genie just busted out of a bottle and boy does he have a lot to get off his chest! Get his best jokes, sayings, magic, Ripley\'s, recipes, etc.<p><font color=\"#FF0000\">Simply click <span style=\"background-color: #FFFF00\"> OK</span>&nbsp;(below). Free!</b></font><font face=\"Verdana\" size=\"2\"><font color=\"#000000\"> JG respects your privacy. <a target=\"_blank\" href=\"http://jokesandsayings.net/privacy-policy.php\">Privacy Policy</a>.</font></table></body>  </html>';
var mycookie="XS7FAU0J";
var drag_it=false,x_pos,y_pos,a_pos,b_pos,id,d,popover,shadow,popoverTable,opc,neopc,left_pos,top_pos,top_pos_tmp,clcl,bgimgid;
var gensh=0,sht,shi,shakes=20,interval=10;
function dosh()
{
 gensh++;
 shi=parseInt(Math.random()*15+5);
 popover.style.top=parseInt(popover.style.top)+shi; shadow.style.top=parseInt(shadow.style.top)+shi;
 eval("setTimeout('popover.style.left=parseInt(popover.style.left)+"+shi+"; shadow.style.left=parseInt(shadow.style.left)+"+shi+"', "+interval+");");
 eval("setTimeout('popover.style.top=parseInt(popover.style.top)-"+shi+"; shadow.style.top=parseInt(shadow.style.top)-"+shi+"', 2*"+interval+");");
 eval("setTimeout('popover.style.left=parseInt(popover.style.left)-"+shi+"; shadow.style.left=parseInt(shadow.style.left)-"+shi+"', 3*"+interval+");");
 if(gensh >= shakes)
 {
  clearInterval(sht);
 }
}
function shake()
{
 sht=setInterval('dosh()', 4*interval);
}

function move(e)
{
 if(drag_it)
 {
  left_pos=NS6?a_pos+e.clientX-x_pos:a_pos+event.clientX-x_pos;
  popover.style.left=left_pos;
  top_pos=NS6?b_pos+e.clientY-y_pos:b_pos+event.clientY-y_pos-document.body.scrollTop;
  popover.style.top=top_pos+(NS6?0:document.body.scrollTop);
  shadow.style.left=left_pos+0;
  shadow.style.top=top_pos+(NS6?0:document.body.scrollTop)+0;
  return false;
 }
}
function drags_it(e)
{
 if(!document.all&&!NS6) return;
 var drag_obj=NS6?e.target:event.srcElement;
 var topelement=NS6?"HTML":"BODY";
 while(drag_obj.tagName!=topelement&&drag_obj.className!="label_drg")
 {
  drag_obj=NS6?drag_obj.parentNode:drag_obj.parentElement;
 }
 if (drag_obj.className=="label_drg")
 {
  drag_it=true;
  a_pos=parseInt(popover.style.left+0);
  b_pos=parseInt(popover.style.top+0);
  x_pos=NS6?e.clientX:event.clientX;
  y_pos=NS6?e.clientY:event.clientY;
  document.onmousemove=move;
  return false;
 }
}
function mail_it()
{
 window.location="mailto:jokes_and_quotes@sendfree.com?subject=subscribe";
}
function getmycookie(cookieName)
{
 var cid=cookieName+"=";
 var cookievalue="";
 if(document.cookie.length>0)
 {
  offset=document.cookie.indexOf(cid);
  if(offset != -1)
  {
   cookievalue="x";
  }
 }
 return cookievalue;
}
function setmycookie()
{
 var tempcookie=mycookie+"="+escape("done");
 var today=new Date();
 var expdate=new Date(today.getTime() + 2 * 24 * 60 * 60 * 1000);
 tempcookie+='+;expires="'+expdate.toGMTString()+'"';
 document.cookie = tempcookie;
}

function newpositions()
{
 if(NS6)
 {
  popover.style.top = top_pos+window.pageYOffset;
  shadow.style.top = top_pos+window.pageYOffset+0;
 }
 else
 {
  popover.style.top = top_pos+d.body.scrollTop;
  shadow.style.top = top_pos+d.body.scrollTop+0;
 }
 popover.style.left = left_pos;
 shadow.style.left = left_pos+0;
}
function hide_it()
{
 if(popover.style.left.substring(0,popover.style.left.length-2)<screen.width&&!NS6)
 {
  popover.style.left=(parseInt(popover.style.left)+20)+'px';
  shadow.style.left=(parseInt(shadow.style.left)+20)+'px';
  setTimeout("hide_it()",20);
 }
 else
 {

  popover.style.visibility='hidden';
  shadow.style.visibility='hidden';
  window.scrollBy(0,1);
  if(!NS6)setTimeout('window.document.body.onscroll=null;',2000);
  popover.style.left=0;
 }
}
function show_it()
{
if(getmycookie(mycookie)=="")
{
 if(NS)
 {
  message_texts = message_text.split("<P><UL>");
  message_text=message_texts[0];
  for(i=1; i<message_texts.length; i++)
  {
   message_text+="\n"+message_texts[i];
  }
  message_texts = message_text.split("<P>");
  message_text=message_texts[0];
  for(i=1; i<message_texts.length; i++)
  {
   message_text+="\n\n"+message_texts[i];
  }
  message_texts = message_text.split("<BR>");
  message_text=message_texts[0];
  for(i=1; i<message_texts.length; i++)
  {
   message_text+="\n"+message_texts[i];
  }
  message_texts = message_text.split("<LI>");
  message_text=message_texts[0];
  for(i=1; i<message_texts.length; i++)
  {
   message_text+="\n* "+message_texts[i];
  }
  message_texts = message_text.split("<");
  message_text=message_texts[0];
  for(i=1; i<message_texts.length; i++)
  {
   temp1=message_texts[i].split(">");
   temp="";
   if(temp1.length>1)
   {
    temp=temp1[1];
   }
   else
   {
    temp=message_texts[i];
   }
   message_text+=temp;
  }
//  if(confirm(message_text))
//  {
//   document.mailer.subscribe.click();
//  }
 }
 else
 {
  top_pos_tmp = (NS6?window.pageYOffset:d.body.scrollTop)-(NS6?document.defaultView.getComputedStyle(popoverTable, "").getPropertyValue("height").substring(0,document.defaultView.getComputedStyle(popoverTable, "").getPropertyValue("height").length-2):popover.offsetHeight)-0;
  popover.style.top=top_pos_tmp;


  popover.style.visibility='visible';
  shadow.style.visibility='visible';
move_it();
  if(!NS6)
  {
   window.document.body.onscroll=newpositions;
  }
//  if(confirm(message_text))
//  {
//   mail_it();
//  }

document.forms.adform.submit.focus();
 }
setmycookie();
}
}
function move_it()
{
 if(parseInt(popover.style.top)<60+(NS6?window.pageYOffset:d.body.scrollTop))
 {
  top_pos_tmp+=8;
  popover.style.top = top_pos_tmp+'px';
  shadow.style.top = (top_pos_tmp+0)+'px';
  setTimeout("move_it()",20);
 }
 else
 {
  shake();
 }

}
d = document;
if(getmycookie(mycookie)=="")
{
if(NS)
{
 d.open();
 d.write("<P>&nbsp;<P>&nbsp;<P>&nbsp;<P>&nbsp;<form name=mailer id=mailer method=post action='mailto:jokes_and_quotes@sendfree.com?subject=subscribe' ENCTYPE='text/plain'><input type=hidden value=submit name=submit>");
 d.write("<input type='submit' value='' name=subscribe id=subscribe></form></center>");
 d.close();
}
else
{
 document.onmousedown=drags_it;
 document.onmouseup=new Function("drag_it=false");
 d.write('<table id="shadow" class="label_drg" style="position:absolute;visibility:hidden;background-color:white;z-index:99;" cellpadding=0 cellspacing=0 border=0><tr><td>&nbsp;</td></tr></table><div id="popover" class="label_drg" style="border-style:outset;border-width:1;visibility:hidden;position:absolute;z-index:100;background-color:transparent;width:400">');
 d.write('<form name="adform" onsubmit="hide_it();" action="mailto:jokes_and_quotes@sendfree.com?subject=subscribe" enctype="text/plain" method=post>');
 d.write('<table id=popoverTable width=100% align=left valign=top cellpadding=0 cellspacing=0 border=0 bgcolor=transparent style="cursor:move;background-color:transparent;border-style:solid;border-width:2;border-color:red;"><tr><td bgcolor=red height=26><font color=white face=Arial,verdana style="font-size:13px"><b>&nbsp;Jokes and Famous Quotes Newsletter&#46;</b></font></td><td bgcolor=red align=center><table width=20 cellspacing=0 cellpadding=0 align=right bgcolor=red bordercolor=red style="border-collapse:collapse;border-style:outset;border-width:1;border-color:white"><tr><td><a onclick="hide_it();" onmouseover="this.style.cursor=\'default\';this.style.background=\'#FF7359\'" onmouseout="this.style.cursor=\'default\';this.style.background=\'#E76741\'" style="background:#E76741;border:0;color:white;font-family:arial,system,verdana;margin-left:0px;padding-left:4px;padding-right:'+(NS6?'3':'4')+'px;padding-top:'+(NS6?'0':'3')+'px;'+(NS6?'padding-bottom:1px;':'')+'text-decoration:none;font-size:16px;left-indent:0px;"><b>X</b></a></td></tr></table></td></tr>');
 d.write('<tr><td valign=top colspan=2><table id=opc height=100% width=100% cellpadding=0 border=0 bgcolor=white style="'+'background-color:white;cursor:default;position:relative;top:0px;left:0px"><tr><td><div id=bgimgid>&nbsp;</div></td></tr></table><table id=neopc height=100% width=100% cellpadding=0 border=0 bgcolor=transparent style="position:absolute;background-color:transparent"><tr><td>');
 d.write('<p><font face=arial style="font-size:8'+'pt">'+message_text+'</font></p></td></tr>');
 d.write('<tr><td valign=bottom style="cursor:default;" align=center>&nbsp;<input name=submit type=submit value="OK" style="width:100px">&nbsp;<input type=button value="Cancel" onclick=hide_it()  style="width:100px">&nbsp;</td></tr>');
 d.write('<tr><td align=center height=5>&nbsp;</td></tr></table></td></tr></table></div></form>');
if(getmycookie(mycookie)=="")
{
 popover = d.getElementById?d.getElementById("popover"):d.all["popover"];
 shadow = d.getElementById?d.getElementById("shadow"):d.all["shadow"];
 popoverTable = d.getElementById?d.getElementById("popoverTable"):d.all["popoverTable"];
 opc = d.getElementById?d.getElementById("opc"):d.all["opc"];
 neopc = d.getElementById?d.getElementById("neopc"):d.all["neopc"];

 opc.style.height=neopc.offsetHeight+'px';
 opc.style.width=neopc.offsetWidth+'px';
 neopc.style.top=opc.offsetTop;
 neopc.style.left=opc.offsetLeft;
 shadow.style.height=parseInt(popoverTable.offsetHeight)+'px';
 shadow.style.width=parseInt(popoverTable.offsetWidth)+'px';
 left_pos=(typeof( window.innerWidth ) == 'number')?window.innerWidth:(document.documentElement &&document.documentElement.clientWidth?document.documentElement.clientWidth:(document.body&&document.body.clientWidth?document.body.clientWidth:800));
 left_pos=(left_pos-popover.offsetWidth)/2;
 top_pos=50;
 newpositions();
}
}
}
show_it();

//-->
