// JavaScript Document
<!--

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
// end of rolover image



function highlightButton(s) {
    if ("INPUT"==event.srcElement.tagName)
      event.srcElement.className=s
}
function textCounter(field,cntfield,maxlimit) {
if (field.value.length > maxlimit) // if too long...trim it!
field.value = field.value.substring(0, maxlimit);
// otherwise, update 'characters left' counter
else
cntfield.value = maxlimit - field.value.length;
}
function highlightButton(s) {
    if ("INPUT"==event.srcElement.tagName)
      event.srcElement.className=s
} 



function new_window(url) {

escortprofile = void(0);
escortprofile = window.open(url,"profile","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=yes,width=820,height=700,left=150,top=10");

if (!escortprofile) {
		document.location.href="/errors.php?errorNr=36";
	} else {
		escortprofile.focus();  // open new profile in the same window 
	}


}

function message_window(url) {

message = void(0);
message = window.open(url,"message","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=yes,width=820,height=480,left=150,top=10");

if (!message) {
		document.location.href="/errors.php?errorNr=36";
	} else {
		message.focus();  // open new e-mail message in the same window 
	}


}

function email_window(url) {

email = window.open(url,"email","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0,width=500,height=350,left=230,top=90");
if (!email) {
		document.location.href="/errors.php?errorNr=36";
	} else {
		email.focus();
	}


}

function chat_window(url) {

email = window.open(url,"email","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0,width=530,height=470,left=230,top=90");
if (!email) {
		document.location.href="/errors.php?errorNr=36";
	} else {
		email.focus();
	}



}



<!--
document.onmousemove = beSmart;
window.onload = init;
startEnlarge = 300;  // The distance to start enlarging the picture at, in pixels.
enlargeTo = 110;     // The number of Pixels to enlarge to.
minSize = 70;        // The number of Pixels to shrink to.
centerOfPic = new Array();

// Calls the beSmart function to set each "smart" image to the correct size.
function init(){
  beSmart();
}

function beSmart(){
  for(i=0;i<document.images.length;i++){

    if(document.images[i].className == "smart"){
	  mouseX = window.event.x;
      mouseY = window.event.y;
      imageX = document.images[i].offsetLeft + (document.images[i].width / 2);
      imageY = document.images[i].offsetTop + (document.images[i].height / 2);
      distance = Math.ceil(Math.sqrt(Math.pow(mouseX  - imageX,2) + Math.pow(imageY - mouseY,2)));
      percent = distance  / startEnlarge * enlargeTo;
      percent = enlargeTo - percent;
         if(percent > minSize){
           document.images[i].style.width = percent;
           document.images[i].style.height = percent;
         } else {
           document.images[i].style.width = minSize;
           document.images[i].style.height = minSize;
         }
    }

  }
}
// -->

// There is no layer created as yet
var trigger=0
// There is no activated Layer
var vis=0
function initthumb()
	{
		document.onmousemove = sniff
		document.onmouseup = sniff
		document.onmousedown = sniff
		// Trigger Netscape Mouse Check
		if (document.layers){document.captureEvents(Event.MOUSEDOWN | Event.MOUSEMOVE | Event.MOUSEUP)}
		// Call dummy to help IE get width + height
		if (document.all)dopic('dummy','',1,1,1,1)
	}
function sniff(e){
		// GETS Mouseposition
		if (document.layers) {var mousex=e.pageX; var mousey=e.pageY;fx=mousex;fy=mousey;}
		else if (document.all) {var mousex=event.x; var mousey=event.y+document.body.scrollTop;fx=mousex;fy=mousey}
				}		
function dopic(name,auto,picx,picy)
{
if (vis=0){clearpic();}
	if (vis == 0) // No layer active, as double layers would bug :(
		{
			// Default coordinates/offsets
			var oldpicx=100;
			var oldpicy=100;
			//border-color
			var rahmen='black'
			// Alt-text
			var alttext="Click to close the picture"

				// When there is no layer...
					if (trigger!=1)
						{
						trigger=1 // There is a layer now!
						// Create hidden layer (Netscape)
							if(document.layers){
								//Piclayer
								document.layers['picarea'] = new Layer(1);
								document.layers['picarea'].left = oldpicx;
								document.layers['picarea'].top = oldpicy;
								document.layers['picarea'].height = 20;
								document.layers['picarea'].visibility = "hidden";
							}
						// Create hidden Layer in Internet Explorer
							else if (document.all){
								document.body.insertAdjacentHTML("BeforeEnd",'<DIV ID="picarea" STYLE="z-index:300;position:absolute;left:"+picx+";top:"+picy></DIV>');
							}
						}

				// If there is a layer, hide it!
					if (trigger != 0){
						if (document.layers){document.layers['picarea'].visibility="hide"} //Netscape
						if (document.all){picarea.style.visibility="hidden"}
					}
			// Define the layer's content
			content="<a href=\"javascript:clearpic()\" style=\"color:"+rahmen+"\"><img src=\"";
			content=content+name+"\" name=\"pic\" alt=\""+alttext+"\" border=4";
			content=content+"></A>";
			// Write content into layer and show it (Netscape)
				if (document.layers) {
					sprite=document.layers['picarea'].document;
  					sprite.open();
					sprite.write(content);
					sprite.close();
					// If there is no auto set, place the layer at picx and picy
					if (picx != null && auto == ''){ 
						document.layers['picarea'].left = picx;
						document.layers['picarea'].top = picy;
					}
					// If auto is set:
					if (auto != "")
						{ 
						// get the picture width/height
						xw=document.layers['picarea'].document.images['pic'].width 
						yw=document.layers['picarea'].document.images['pic'].height
						// center the picture at mouseposition
						newpicx = fx - (xw/2)
						newpicy = fy - (yw/2)
							// if there are offsets, set them
							if (picx) {newpicx=newpicx + picx}
							if (picy) {newpicy=newpicy + picy} 
						// place layer
						document.layers['picarea'].left = newpicx;
						document.layers['picarea'].top = newpicy;
						}
					// show layer
					document.layers['picarea'].visibility="show";
					// set trigger vor visible layer
					vis=1
				 }

			// Write content into layer and show it (Internet Explorer)
				if (document.all) {
					document.all['picarea'].innerHTML = content;
					// If there is no auto set, place the layer at picx and picy
					if (picx != null && auto == ''){
						picarea.style.top=picy
						picarea.style.left=picx;
					}
					// If auto is set:
					if (auto != "")	{ 
						// get the picture width/height
						xw=document.all['pic'].width
						yw=document.all['pic'].height
						// center the picture at mouseposition
				      newpicx = fx - (xw/2)
				      newpicy = fy - (yw/2)
							// if there are offsets, set them
							if (picx) {newpicx=newpicx + picx}
							if (picy) {newpicy=newpicy + picy} 
						// place layer
						picarea.style.top=newpicy;
						picarea.style.left=newpicx;
					}
					// show layer
					// name is not dummy 		
						if (name != "dummy") {
							picarea.style.visibility="visible";
							// set trigger vor visible layer
							vis=1
						}
	}
	// Older javascript able browser, show the pic
	else if (document.layers == null && document.all == null) {self.location=name};
	}
}
// Hide layers on click
function clearpic()	{
	// deactivate visible trigger 
	vis=0
		if (document.layers){document.layers['picarea'].visibility="hide"};
		if (document.all){picarea.style.visibility="hidden"};
}
	//-->



function send2friend()
{
	element = document.getElementById('overlaydiv');
	element.style.width = ( navigator.userAgent.indexOf ( "MSIE" ) == -1 ? document.documentElement.scrollWidth : document.body.clientWidth ) + "px";
	element.style.height = ( navigator.userAgent.indexOf ( "MSIE" ) == -1 ? document.documentElement.scrollHeight : document.body.clientHeight ) + "px" ;
	
	scrollY = ( document.documentElement ) ? document.documentElement.scrollTop : document.body.scrollTop;
	document.getElementById( "send2friend" ).style.top = (scrollY + 200) + 'px';
	document.getElementById( "overlaydiv" ).style.visibility = document.getElementById('overlaydiv').style.visibility == 'visible' ? 'hidden' : 'visible';
	document.getElementById( "send2friend" ).style.visibility = document.getElementById('send2friend').style.visibility == 'visible' ? 'hidden' : 'visible';
	document.getElementById( "send2friend" ).getElementsByTagName("form")[0]["page"].value = self.location.toString();
}


<!-- new window open
function picopen(img){
  foto1= new Image();
  foto1.src=(img);
  Controlla(img);
}
function Controlla(img){
  if((foto1.width!=0)&&(foto1.height!=0)){
    viewFoto(img);
  }
  else{
    funzione="Controlla('"+img+"')";
    intervallo=setTimeout(funzione,20);
  }
}
function viewFoto(img){
  largh=foto1.width+20;
  altez=foto1.height+20;
  stringa="width="+largh+",height="+altez;
  finestra=window.open(img,"",stringa);
}
/***********************************************
* Image Thumbnail viewer- © Rentmen.com code
***********************************************/

var ie=document.all
var ns6=document.getElementById&&!document.all

function ietruebody(){
return (document.compatMode && document.compatMode!="BackCompat" && !window.opera)? document.documentElement : document.body
}

function enlarge(which, e, position, imgwidth, imgheight){
if (ie||ns6){
crossobj=document.getElementById? document.getElementById("showimage") : document.all.showimage
if (position=="center"){
pgyoffset=ns6? parseInt(pageYOffset) : parseInt(ietruebody().scrollTop)
horzpos=ns6? pageXOffset+window.innerWidth/2-imgwidth/2 : ietruebody().scrollLeft+ietruebody().clientWidth/2-imgwidth/2
vertpos=ns6? pgyoffset+window.innerHeight/2-imgheight/2 : pgyoffset+ietruebody().clientHeight/2-imgheight/2
if (window.opera && window.innerHeight) //compensate for Opera toolbar
vertpos=pgyoffset+window.innerHeight/2-imgheight/2
vertpos=Math.max(pgyoffset, vertpos)
}
else{
var horzpos=ns6? pageXOffset+e.clientX : ietruebody().scrollLeft+event.clientX
var vertpos=ns6? pageYOffset+e.clientY : ietruebody().scrollTop+event.clientY
}
crossobj.style.left=horzpos+"px"
crossobj.style.top=vertpos+"px"

crossobj.innerHTML='<div align="right" id="dragbar" progid:DXImageTransform.Microsoft.Shadow(color=black,direction=135 Strength=2);><span id="closetext" onClick="closepreview()"><img src="GIF/close.gif"  alt="close"> </span> </div><span onClick="closepreview()"><img src="'+which+'"></span>'
crossobj.style.visibility="visible"
return false
}
else //if NOT IE 4+ or NS 6+, simply display image in full browser window
return true
}

function closepreview(){
crossobj.style.visibility="hidden"
}

function drag_drop(e){
if (ie&&dragapproved){
crossobj.style.left=tempx+event.clientX-offsetx+"px"
crossobj.style.top=tempy+event.clientY-offsety+"px"
}
else if (ns6&&dragapproved){
crossobj.style.left=tempx+e.clientX-offsetx+"px"
crossobj.style.top=tempy+e.clientY-offsety+"px"
}
return false
}

function initializedrag(e){
if (ie&&event.srcElement.id=="dragbar"||ns6&&e.target.id=="dragbar"){
offsetx=ie? event.clientX : e.clientX
offsety=ie? event.clientY : e.clientY

tempx=parseInt(crossobj.style.left)
tempy=parseInt(crossobj.style.top)

dragapproved=true
document.onmousemove=drag_drop
}
}

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

function swapstar(num,src,text,id)
{ 
	switch(num)
	{
		case 1:
			document.getElementById("star1-"+id).src=document.getElementById("star1-"+id).getAttribute(src);
			document.getElementById("star_r-"+id).innerHTML="&nbsp;&nbsp;"+text;
		break;
		case 2:
			document.getElementById("star1-"+id).src=document.getElementById("star1-"+id).getAttribute(src); 
			document.getElementById("star2-"+id).src=document.getElementById("star2-"+id).getAttribute(src); 
			document.getElementById("star_r-"+id).innerHTML="&nbsp;&nbsp;"+text;
		break;
		case 3:
			document.getElementById("star1-"+id).src=document.getElementById("star1-"+id).getAttribute(src); 
			document.getElementById("star2-"+id).src=document.getElementById("star2-"+id).getAttribute(src); 
			document.getElementById("star3-"+id).src=document.getElementById("star3-"+id).getAttribute(src); 
			document.getElementById("star_r-"+id).innerHTML="&nbsp;&nbsp;"+text;
		break;
		case 4:
			document.getElementById("star1-"+id).src=document.getElementById("star1-"+id).getAttribute(src); 
			document.getElementById("star2-"+id).src=document.getElementById("star2-"+id).getAttribute(src); 
			document.getElementById("star3-"+id).src=document.getElementById("star3-"+id).getAttribute(src); 
			document.getElementById("star4-"+id).src=document.getElementById("star4-"+id).getAttribute(src); 
			document.getElementById("star_r-"+id).innerHTML="&nbsp;&nbsp;"+text;
		break;
		default:
			document.getElementById("star1-"+id).src=document.getElementById("star1-"+id).getAttribute(src); 
			document.getElementById("star2-"+id).src=document.getElementById("star2-"+id).getAttribute(src); 
			document.getElementById("star3-"+id).src=document.getElementById("star3-"+id).getAttribute(src); 
			document.getElementById("star4-"+id).src=document.getElementById("star4-"+id).getAttribute(src); 
			document.getElementById("star5-"+id).src=document.getElementById("star5-"+id).getAttribute(src); 
			document.getElementById("star_r-"+id).innerHTML="&nbsp;&nbsp;"+text;
		break;
	}
}
<!--
/*strech website
*/
var head="display:''"
function doit(header){
var head=header.style
if (head.display=="none")
head.display=""
else
head.display="none"
}

function pcinfo()  //user's screen size
{
var w=screen.width;
var h=screen.height;
var ref=document.referrer;

// To find Browser and Version
NETSCAPE = navigator.appName == "Netscape";
MSIE = navigator.appName == "IE";
if ((ver = parseInt(navigator.appVersion)) == 4 && MSIE == true){
  if (/4\.\d+\D+(\d+)\D/.test(navigator.appVersion)){
    ver = RegExp.$1;
  }
}

document.getElementById('hiddenField1').value=w;
document.getElementById('hiddenField2').value=h;
document.getElementById('hiddenField3').value=ref;
document.getElementById('hiddenField4').value=ver;
document.getElementById('hiddenField5').value=navigator.appName;
}

//-->