var xmlHttp=false;function showform(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request");return;}
var url="registerpopup.php";url=url+"?q="+str;url=url+"&sid="+Math.random();xmlHttp.onreadystatechange=stateChanged;xmlHttp.open("GET",url,true);xmlHttp.send(null);}
function showloginform(str)
{xmlHttp=GetXmlHttpObject();if(xmlHttp==null)
{alert("Browser does not support HTTP Request");return;}
var url="loginpopup.php";url=url+"?q="+str;url=url+"&sid="+Math.random();xmlHttp.onreadystatechange=stateChangedLogin1;xmlHttp.open("GET",url,true);xmlHttp.send(null);}
function showforgotpasswordform(str)
{xmlHttp=GetXmlHttpObject();if(xmlHttp==null)
{alert("Browser does not support HTTP Request");return;}
var url="retrieve_passwordpopup.php";url=url+"?q="+str;url=url+"&sid="+Math.random();xmlHttp.onreadystatechange=forgotpasswordformstateChanged;xmlHttp.open("GET",url,true);xmlHttp.send(null);}
function form_submit_for_checkavailability(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('username').value=="")
{alert("Please Enter User Name");registration_form.username.focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="registerpopup.php"
var params="name="+document.getElementById('name').value;params=params+"&email="+document.getElementById('email').value;params=params+"&email_check="+document.getElementById('email_check').value;params=params+"&username="+document.getElementById('username').value;params=params+"&password="+document.getElementById('password').value;params=params+"&password2="+document.getElementById('password2').value;params=params+"&pin_value="+document.getElementById('pin_value').value;params=params+"&pin_value_hdn="+document.getElementById('pin_value_hdn').value;params=params+"&newsletter="+document.getElementById('newsletter').value;xmlHttp.open("GET",url+"?"+params,true);xmlHttp.onreadystatechange=stateChanged;xmlHttp.send(null);}}
function form_submit_quick_register(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('name').value=="")
{alert("Please enter full name.");registration_form.name.focus();return false;}
if((document.getElementById('email').value=="")||(document.getElementById('email').value.indexOf('@')==-1)||(document.getElementById('email').value.indexOf('.')==-1))
{alert("Please give your correct email address.");registration_form.email.focus();return false;}
if(document.getElementById('email_check').value=="")
{alert("Please enter retype email address.");registration_form.email_check.focus();return false;}
if(document.getElementById('email').value!=document.getElementById('email_check').value)
{alert("Email address and retype email address does not match.");registration_form.email_check.focus();return false;}
if(document.getElementById('username').value=="")
{alert("Please enter username.");registration_form.username.focus();return false;}
if(document.getElementById('password').value.length<6)
{alert("Please enter password (6 characters minimum).");registration_form.password.focus();return false;}
if(document.getElementById('password').value!=document.getElementById('password2').value)
{alert("Password and verify password does not match.");registration_form.password2.focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter registration PIN.");registration_form.pin_value.focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Registration PIN does not match.");registration_form.pin_value.focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="registerpopup.php?operation=submit"
var params="&name="+document.getElementById('name').value;params=params+"&email="+document.getElementById('email').value;params=params+"&email_check="+document.getElementById('email_check').value;params=params+"&username="+document.getElementById('username').value;params=params+"&password="+document.getElementById('password').value;params=params+"&password2="+document.getElementById('password2').value;params=params+"&pin_value="+document.getElementById('pin_value').value;params=params+"&pin_value_hdn="+document.getElementById('pin_value_hdn').value;params=params+"&newsletter="+document.getElementById('newsletter').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=stateChanged
xmlHttp.send(null)}}
function form_submit_quick_login(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('username').value=="")
{alert("Please enter user name.");document.getElementById('username').focus();return false;}
if(document.getElementById('password').value=="")
{alert("Please enter password.");document.getElementById('password').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="loginpopup.php?operation=submit&redirect=sell_item.php"
var params="&username="+document.getElementById('username').value;params=params+"&password="+document.getElementById('password').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=stateChangedLogin1
xmlHttp.send(null)}}
function form_submit_retrive_password(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('email').value=="")
{alert("Please enter email address.");document.getElementById('email').focus();return false;}
if(document.getElementById('username').value=="")
{alert("Please enter user name.");document.getElementById('username').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="retrieve_passwordpopup.php?operation=retrieve_password"
var params="&username="+document.getElementById('username').value;params=params+"&email="+document.getElementById('email').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=forgotpasswordformstateChanged
xmlHttp.send(null)}}
function form_submit_retrieve_username(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if(keynum==13||e=='111')
{
	if(document.getElementById('email_address').value=="")
	{alert("Please enter email address.");document.getElementById('email_address').focus();return false;}
	xmlHttp=GetXmlHttpObject()
	if(xmlHttp==null)
	{alert("Browser does not support HTTP Request")
	return 
	}
	var url="retrieve_passwordpopup.php?operation=retrieve_username"
	var params="&email_address="+document.getElementById('email_address').value;
	xmlHttp.open("GET",url+params,true)
	xmlHttp.onreadystatechange=forgotpasswordformstateChanged
	xmlHttp.send(null)
}
}
function form_submit_ask_question()
{if(document.getElementById('message_content').value=="")
{alert("Please enter message_content.");document.getElementById('message_content').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="askquestion.php?option=post_question";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&message_content="+document.getElementById('message_content').value;params=params+"&message_handle="+document.getElementById('message_handle').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=askquestionstatechanged
xmlHttp.send(null)}
function form_submit_ask_questionbuyer()
{if(document.getElementById('message_content').value=="")
{alert("Please enter message_content.");document.getElementById('message_content').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="askquestionbuyer.php?option=post_question";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&message_content="+document.getElementById('message_content').value;params=params+"&message_handle="+document.getElementById('message_handle').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=askquestionstatechanged
xmlHttp.send(null)}
function form_submit_direct_contact_seller(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if((document.getElementById('email').value=="")||(document.getElementById('email').value.indexOf('@')==-1)||(document.getElementById('email').value.indexOf('.')==-1))
{alert("Please give your correct email address.");document.getElementById('email').focus();return false;}
if(document.getElementById('question_content').value=="")
{alert("Please enter message_content.");document.getElementById('question_content').focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter registration PIN.");document.getElementById('pin_value').focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Registration PIN does not match.");document.getElementById('pin_value').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="contactseller.php?option=submit";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&name="+document.getElementById('name').value;params=params+"&email="+document.getElementById('email').value;params=params+"&question_content="+document.getElementById('question_content').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.send(null)}}
function form_submit_direct_contact_buyer(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if((document.getElementById('email').value=="")||(document.getElementById('email').value.indexOf('@')==-1)||(document.getElementById('email').value.indexOf('.')==-1))
{alert("Please give your correct email address.");document.getElementById('email').focus();return false;}
if(document.getElementById('question_content').value=="")
{alert("Please enter message_content.");document.getElementById('question_content').focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter registration PIN.");document.getElementById('pin_value').focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Registration PIN does not match.");document.getElementById('pin_value').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="contactbuyer.php?option=submit";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&name="+document.getElementById('name').value;params=params+"&email="+document.getElementById('email').value;params=params+"&question_content="+document.getElementById('question_content').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.send(null)}}
function form_submit_did_you_like(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if((document.getElementById('email').value=="")||(document.getElementById('email').value.indexOf('@')==-1)||(document.getElementById('email').value.indexOf('.')==-1))
{alert("Please give your correct email address.");document.getElementById('email').focus();return false;}
if(document.getElementById('question_content').value=="")
{alert("Please enter message_content.");document.getElementById('question_content').focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter registration PIN.");document.getElementById('pin_value').focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Registration PIN does not match.");document.getElementById('pin_value').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="didyoulike.php?option=submit";var params="&name="+document.getElementById('name').value;params=params+"&email="+document.getElementById('email').value;params=params+"&question_content="+document.getElementById('question_content').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=didyoulikestatechanged
xmlHttp.send(null)}}
function form_submit_send_to_friend(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if((document.getElementById('friend_email').value=="")||(document.getElementById('friend_email').value.indexOf('@')==-1)||(document.getElementById('friend_email').value.indexOf('.')==-1))
{alert("Please give your correct email address.");document.getElementById('friend_email').focus();return false;}
if(document.getElementById('comments').value=="")
{alert("Please enter comments.");document.getElementById('comments').comments.focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter registration PIN.");document.getElementById('pin_value').focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Registration PIN does not match.");document.getElementById('pin_value').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="auction_friend.php?option=submit";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&friend_name="+document.getElementById('friend_name').value;params=params+"&friend_email="+document.getElementById('friend_email').value;params=params+"&comments="+document.getElementById('comments').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.send(null)}}
function form_submit_send_to_friends_2()
{if(document.getElementById('question_content').value=="")
{alert("Please enter comments.");document.getElementById('question_content').focus();return false;}
if(document.getElementById('pin_value').value=="")
{alert("Please enter Confirm PIN.");document.getElementById('pin_value').focus();return false;}
if(document.getElementById('pin_value').value!=document.getElementById('pin_value_hdn').value)
{alert("Confirm PIN does not match.");document.getElementById('pin_value').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="auction_friends.php?form_contactus_send=1";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&usernamegym="+document.getElementById('usernamegym').value;params=params+"&password="+document.getElementById('password').value;params=params+"&provider="+document.getElementById('provider').value;params=params+"&fromemail="+document.getElementById('fromemail').value;params=params+"&totalemail="+document.getElementById('totalemail').value;params=params+"&question_content="+document.getElementById('question_content').value;t_len=document.getElementById('totalemail').value;var countchked=0;var selectedvalue="";check_sel=false;for(i=1;i<=t_len;i++)
{if(document.getElementById("email"+i).checked==true)
{check_sel=true;countchked++;selectedvalue=selectedvalue+","+document.getElementById("email"+i).value}}
if(check_sel==false)
{alert("Please Select Atleast One Email Id.");return false;}
params=params+"&emails="+selectedvalue;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=showsendtofriends2statechanged
xmlHttp.send(null)}
function form_submit_send_to_friends_1(e)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('usernamegym').value=="")
{alert("Please Enter Email Id");document.getElementById('usernamegym').focus();return false;}
if(document.getElementById('password').value=="")
{alert("Please Enter Password");document.getElementById('password').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="auction_friends.php?form_contacts_load=1";var params="&auction_id="+document.getElementById('auction_id').value;params=params+"&usernamegym="+document.getElementById('usernamegym').value;params=params+"&password="+document.getElementById('password').value;params=params+"&provider="+document.getElementById('provider').value;params=params+"&select_provider_main="+document.getElementById('select_provider_main').value;xmlHttp.open("GET",url+params,true)
xmlHttp.onreadystatechange=showsendtofriends2statechanged
xmlHttp.send(null)}}
function showloginformauctiondetails(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="loginpopup.php"
url=url+"?frmid="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=stateChangedLoginauction
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showloginformbidbuyoutmakeoffer(str,str2)
{if(str2=='bid')
{if(document.getElementById('max_bid').value=="")
{alert("Please enter your maximum bid.");document.getElementById('max_bid').focus();return false;}}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="loginpopup.php"
url=url+"?frmid="+str
url=url+"&frmid2="+str2
url=url+"&sid="+Math.random()
var params='';if(str2=='bid')
params="&max_bid="+document.getElementById('max_bid').value;xmlHttp.onreadystatechange=stateChangedLoginauction
xmlHttp.open("GET",url+params,true)
xmlHttp.send(null)}
function showloginforaskbuyer(str,str2)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="loginpopup.php"
url=url+"?frmid="+str
url=url+"&frmid2="+str2
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=stateChangedLoginauction
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function setfcs()
{}
function form_submit_quick_login_foraskquestion(e,str,str2,max_bid)
{var keynum;if(window.event)
{keynum=e.keyCode;}
else if(e.which)
{keynum=e.which;}
if((keynum==13||e=='111'))
{if(document.getElementById('username').value=="")
{alert("Please enter user name.");document.getElementById('username').focus();return false;}
if(document.getElementById('password').value=="")
{alert("Please enter password.");document.getElementById('password').focus();return false;}
xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="loginpopup.php?operation=submit&redirect=sell_item.php"
var params="&username="+document.getElementById('username').value;params=params+"&password="+document.getElementById('password').value;params=params+"&frmid="+str;params=params+"&frmid2="+str2;params=params+"&max_bid="+max_bid;xmlHttp.open("GET",url+params,true)
if(str=='mybidcayman'&&str2=='')
{xmlHttp.onreadystatechange=stateChangedLoginformybidcayman}
else if(str=='wantedadslk'&&str2=='')
{xmlHttp.onreadystatechange=stateChangedLoginwantedadslk}
else if(str2=='bid'||str2=='buy'||str2=='mak')
{xmlHttp.onreadystatechange=bidloginstatechanged}
else if(str2=='askbuyer')
{xmlHttp.onreadystatechange=stateChangedLoginforaskbuyer}
else
{xmlHttp.onreadystatechange=stateChangedLoginauctionnew}
xmlHttp.send(null)}}
function showaskquestion(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="askquestion.php"
url=url+"?auction_id="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=askquestionstatechanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showaskquestionbuyer(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="askquestionbuyer.php"
url=url+"?auction_id="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=askquestionstatechanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showdirectcontactseller(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="contactseller.php"
url=url+"?auction_id="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showdirectcontactbuyer(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="contactbuyer.php"
url=url+"?auction_id="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showdidyoulike(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="didyoulike.php?page="+str
xmlHttp.onreadystatechange=didyoulikestatechanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function ajaxshowcategories()
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="browsecategories.php"
xmlHttp.onreadystatechange=stateChangedBrowseCategories
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showsendtofriend(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="auction_friend.php"
url=url+"?auction_id="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=directcontactstateChanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function showsendtofriends(str,str1)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="auction_friends.php"
url=url+"?auction_id="+str
url=url+"&provider_id="+str1
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=showsendtofriends1statechanged
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function buildDimmerDiv()
{}
function showpaidfeature(str)
{xmlHttp=GetXmlHttpObject()
if(xmlHttp==null)
{alert("Browser does not support HTTP Request")
return}
var url="paidfeatureinfo.php"
url=url+"?featureid="+str
xmlHttp.onreadystatechange=stateChangedfeature
xmlHttp.open("GET",url,true)
xmlHttp.send(null)}
function stateChangedfeature()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if(xmlHttp.readyState==4||xmlHttp.readyState=="complete")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.height=200;document.getElementById('dvregisterfrm').style.width=400;document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}}
function stateChangedLoginauction()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var str1=str.substring(strlengthcount-7,strlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function stateChangedLoginauctionnew()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var str1=str.substring(strlengthcount-13,strlengthcount-6);var auctionid=str.substring(strlengthcount-6,strlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";showaskquestion(auctionid)}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function stateChangedLoginforaskbuyer()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var finalstrlengthcount=strlengthcount-4;var finalstr=str.substring(strlengthcount-finalstrlengthcount,strlengthcount-8);var str1=finalstr.substring(0,7);var auctionid=finalstr.substring(7,finalstr.length);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";showaskquestionbuyer(auctionid)}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function bidloginstatechanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var finalstrlengthcount=strlengthcount-5;var finalstr=str.substring(strlengthcount-finalstrlengthcount,strlengthcount);var str1=finalstr.substring(0,7);var auctionid=finalstr.substring(7,13);var max_bid=finalstr.substring(13,finalstrlengthcount-3);var linkoption=finalstr.substring(finalstrlengthcount-3,finalstrlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";var url123='';if(linkoption=='bid')
url123="bid.php"
else if(linkoption=='buy')
url123="buy_out.php"
else if(linkoption=='mak')
url123="make_offer.php"
url123=url123+"?auction_id="+auctionid
if(linkoption=='bid')
{url123=url123+"&max_bid="+max_bid
url123=url123+"&action=bid_confirm"}
document.location.href=url123;}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function stateChangedLoginformybidcayman()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var str1=str.substring(strlengthcount-18,strlengthcount-11);var auctionid=str.substring(strlengthcount-6,strlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
document.tp.username.focus();unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";document.location.href='members_area.php';}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function stateChangedLoginwantedadslk()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var str1=str.substring(strlengthcount-18,strlengthcount-11);var auctionid=str.substring(strlengthcount-6,strlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height=275;document.getElementById('dvregisterfrm').style.top=CalculateTop('275');;document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');;document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";document.location.href='members_area.php?page=wanted_ads&section=new';}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function directcontactstateChanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.width='350';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>1600)
{document.getElementById('dvregisterfrm').style.height='370';document.getElementById('dvregisterfrm').style.top=CalculateTop('370');}
else
{document.getElementById('dvregisterfrm').style.height='150';document.getElementById('dvregisterfrm').style.top=CalculateTop('150');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('350');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function askquestionstatechanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.width='350';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>1600)
{document.getElementById('dvregisterfrm').style.height='300';document.getElementById('dvregisterfrm').style.top=CalculateTop('300');}
else
{document.getElementById('dvregisterfrm').style.height='100';document.getElementById('dvregisterfrm').style.top=CalculateTop('100');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('350');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function didyoulikestatechanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.width='350';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>1600)
{document.getElementById('dvregisterfrm').style.height='370';document.getElementById('dvregisterfrm').style.top=CalculateTop('370');}
else
{document.getElementById('dvregisterfrm').style.height='150';document.getElementById('dvregisterfrm').style.top=CalculateTop('150');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('350');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function showsendtofriends1statechanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.width='350';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>1550)
{document.getElementById('dvregisterfrm').style.height='250';document.getElementById('dvregisterfrm').style.top=CalculateTop('250');}
else
{document.getElementById('dvregisterfrm').style.height='150';document.getElementById('dvregisterfrm').style.top=CalculateTop('150');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('350');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function showsendtofriends2statechanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.width='400';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>2200)
{document.getElementById('dvregisterfrm').style.height='450';document.getElementById('dvregisterfrm').style.top=CalculateTop('450');}
else
{document.getElementById('dvregisterfrm').style.height='150';document.getElementById('dvregisterfrm').style.top=CalculateTop('150');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('400');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function forgotpasswordformstateChanged()
{
	SetBackground();
	if(xmlHttp.readyState==1)
	{ProcessLoader();}
	if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
	{
		document.getElementById('dvprocessing').style.display='none';
		document.getElementById('dvregisterfrm').style.width='450';
		document.getElementById('dvregisterfrm').style.height='200';
		document.getElementById('dvregisterfrm').style.top=CalculateTop('200');
		document.getElementById('dvregisterfrm').style.left=CalculateLeft('450');
		document.getElementById('dvregisterfrm').style.display='';
		document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;
		unhideIframe();
	 }
}
function stateChanged()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if(xmlHttp.readyState==4||xmlHttp.readyState=="complete")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.display='';document.getElementById('dvregisterfrm').style.width='477';var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;if(strlengthcount>1200)
{document.getElementById('dvregisterfrm').style.height='473';document.getElementById('dvregisterfrm').style.top=CalculateTop('473');}
else
{document.getElementById('dvregisterfrm').style.height='150';document.getElementById('dvregisterfrm').style.top=CalculateTop('150');}
document.getElementById('dvregisterfrm').style.left=CalculateLeft('477');document.getElementById('dvregisterfrm').style.backgroundColor='#FFFFFF';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText;unhideIframe();}}
function trim(str,chars)
{return ltrim(rtrim(str,chars),chars);}
function ltrim(str,chars)
{chars=chars||"\\s";return str.replace(new RegExp("^["+chars+"]+","g"),"");}
function rtrim(str,chars)
{chars=chars||"\\s";return str.replace(new RegExp("["+chars+"]+$","g"),"");}
function stateChangedLogin1()
{SetBackground();if(xmlHttp.readyState==1)
{ProcessLoader();}
if((xmlHttp.readyState==4||xmlHttp.readyState=="complete")&&(xmlHttp.status==200))
{var str=trim(xmlHttp.responseText,' ');var strlengthcount=str.length;var str1=str.substring(strlengthcount-7,strlengthcount);if(str1!="success")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm').style.height='275';document.getElementById('dvregisterfrm').style.width='270';document.getElementById('dvregisterfrm').style.top=CalculateTop('275');document.getElementById('dvregisterfrm').style.left=CalculateLeft('270');document.getElementById('dvregisterfrm').style.display='';document.getElementById("dvregisterfrm").innerHTML=xmlHttp.responseText
unhideIframe();}
else
{document.getElementById('dvregisterfrm').style.display="none";document.location.href='sell_item.php';}}
else if((xmlHttp.readyState==4||xmlHttp.readyState=="complete"))
{}}
function stateChangedBrowseCategories()
{if(xmlHttp.readyState==1)
{ProcessLoader();}
if(xmlHttp.readyState==4||xmlHttp.readyState=="complete")
{document.getElementById('dvprocessing').style.display='none';document.getElementById('dvregisterfrm123').style.display='';document.getElementById('dvregisterfrm123').style.width='580';document.getElementById('dvregisterfrm123').style.height='240';document.getElementById('dvregisterfrm123').style.backgroundColor='#FFFFFF';document.getElementById("dvregisterfrm123").innerHTML=xmlHttp.responseText;unhideIframe123();}}
function GetXmlHttpObject()
{var xmlHttp=null;try
{xmlHttp=new XMLHttpRequest();}
catch(e)
{try
{xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");}
catch(e)
{xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");}}
return xmlHttp;}
function ProcessLoader()
{document.getElementById('dvprocessing').style.display = '';// document.getElementById('dvprocessing').innerHTML="<img src='images/ajax-loader.gif'>";document.getElementById('dvprocessing').style.display='';document.getElementById('dvprocessing').style.width='';document.getElementById('dvprocessing').style.height='';document.getElementById('dvprocessing').style.top=CalculateTop('32');document.getElementById('dvprocessing').style.left=CalculateLeft('32');document.getElementById('dvprocessing').style.backgroundColor='white';
}
function SetBackground()
{document.getElementById('dimmer').style.width=GetBodyWidth();document.getElementById('dimmer').style.height=GetBodyHeight();document.getElementById('dimmer').style.visibility="visible";}
function checkall123()
{var a,sel;if(document.emaillist.chkHeader.checked==true)
{sel=true;}
else
{sel=false;}
for(var i=0;i<document.emaillist.length;i++)
{if(document.emaillist.elements[i].type=="checkbox")
{document.emaillist.elements[i].checked=sel;}}}
function CalculateLeft(Weight)
{var ScrollLeft=document.body.scrollLeft;if(ScrollLeft==0)
{if(window.pageXOffset)
ScrollLeft=window.pageXOffset;else
ScrollLeft=(document.body.parentElement)?document.body.parentElement.scrollLeft:0;}
var BodyWeight=document.documentElement.clientWidth;if(BodyWeight==0)
{BodyWeight=document.body.clientWidth;}
var FinalLeft=(BodyWeight+ScrollLeft-Weight)/2;return FinalLeft;}
function CalculateTop(Height)
{var ScrollTop=document.body.scrollTop;if(ScrollTop==0)
{if(window.pageYOffset)
ScrollTop=window.pageYOffset;else
ScrollTop=(document.body.parentElement)?document.body.parentElement.scrollTop:0;}
var BodyHeight=document.body.clientHeight;if(BodyHeight==0)
{BodyHeight=window.innerHeight;}
if(BodyHeight==0)
{BodyHeight=document.documentElement.clientHeight}
var FinalTop=((BodyHeight-Height)/2)+ScrollTop;return FinalTop;}
function CalculateHeight()
{var ScrollTop=document.body.scrollTop;if(ScrollTop==0)
{if(window.pageYOffset)
ScrollTop=window.pageYOffset;else
ScrollTop=(document.body.parentElement)?document.body.parentElement.scrollTop:0;}
var BodyHeight=document.body.clientHeight;;if(BodyHeight==0)
{BodyHeight=window.innerHeight;}
if(BodyHeight==0)
{BodyHeight=document.documentElement.clientHeight}
var FinalHeight=(BodyHeight+ScrollTop);return FinalHeight;}
function GetBodyHeight()
{var theHeight1=0;var theHeight2=0;var theHeight3=0;if(window.innerHeight)
{theHeight1=window.innerHeight;}
if(document.documentElement&&document.documentElement.clientHeight)
{theHeight2=document.documentElement.clientHeight;}
if(document.body)
{theHeight3=document.body.clientHeight;if(isMozilla)
{theHeight4=0;}
else
{theHeight4=document.body.scrollHeight;}}
FinalHeight=Math.max(theHeight1,theHeight2,theHeight3,theHeight4);if(isMozilla)
{FinalHeight=FinalHeight-85;}
return FinalHeight;}
function GetBodyWidth()
{var theWidth=0;if(document.body)
{theWidth=document.body.clientWidth;}
else if(document.documentElement&&document.documentElement.clientWidth)
{theWidth=document.documentElement.clientWidth;}
else if(window.innerWidth)
{theWidth=window.innerWidth;}
if(isMozilla)
{theWidth=theWidth-85;}
return theWidth;}
function MouseDown(e)
{if(over)
{if(isMozilla)
{objDiv=document.getElementById(DivID);X=e.layerX;Y=e.layerY;return false;}
else
{objDiv=document.getElementById(DivID);objDiv=objDiv.style;X=event.offsetX;Y=event.offsetY;}}}
function MouseMove(e)
{if(objDiv)
{if(isMozilla)
{objDiv.style.top=(e.pageY-Y)+'px';objDiv.style.left=(e.pageX-X)+'px';return false;}
else
{objDiv.pixelLeft=event.clientX-X+document.body.scrollLeft;objDiv.pixelTop=event.clientY-Y+document.body.scrollTop;return false;}}}
function MouseUp()
{objDiv=null;}
function init()
{isMozilla=(document.all)?0:1;if(isMozilla)
{document.captureEvents(Event.MOUSEDOWN|Event.MOUSEMOVE|Event.MOUSEUP);}
document.onmousedown=MouseDown;document.onmousemove=MouseMove;document.onmouseup=MouseUp;}
init();function hideIframe()
{if(ie)
{var theIframe=document.getElementById("fadeboxiframe")
theIframe.style.display="none";}}
function unhideIframe()
{if(ie)
{var theIframe=document.getElementById("fadeboxiframe")
var theDiv=document.getElementById("dvregisterfrm");theIframe.style.width=theDiv.offsetWidth+'px';theIframe.style.height=theDiv.offsetHeight+'px';theIframe.style.top=theDiv.offsetTop+'px';theIframe.style.left=theDiv.offsetLeft+'px';theIframe.style.display='';}}
function unhideIframe123()
{if(ie)
{var theIframe=document.getElementById("fadeboxiframe123")
var theDiv=document.getElementById("dvregisterfrm123");theIframe.style.width=theDiv.offsetWidth+'px';theIframe.style.height=theDiv.offsetHeight+'px';theIframe.style.top=theDiv.offsetTop+'px';theIframe.style.left=theDiv.offsetLeft+'px';theIframe.style.display='';}}
function body_onkeydown(evt)
{var key=(window.Event)?evt.which:evt.keyCode;if(key==27)
{styledPopupClose();}}




