<!--//
//
// IF YOU SEE THIS UPGRADE YOUR BROWSER !!!
// 
//////////////////////////////////////////////////////////////////////////////////////
//// Hampton Development  -  http://www.hamptondevelopment.us            
//// Commercial Web Site Development & Web Site Hosting                                                       
//// Custom Scripting, Applications & Graphics - Absolutely No Redistribution 
//// Copyright © 1996 - 2004 Hampton Development  All Rights Reserved.                                                   
//////////////////////////////////////////////////////////////////////////////////////
//
// Copyright Script - Alert Message Disabled By Default

defaultStatus="Stone Barn Furnishings, Inc.  -  330-674-2064  -  StoneBarnFurnishings.com"

// var clickmessage="Sorry, no right click over images.\nCopyright © 2001 - 2005 Stone Barn Furnishings, Inc. - All Rights Reserved."

var clickmessage="Sorry, No Right Click Over Images.\nRight Click Menu Is Disabled ONLY Over Copyright Protected Images.\nCopyright © Stone Barn Furnishings, Inc. - All Rights Reserved." 

function disableclick(e) {
if (document.all) {
if (event.button==2||event.button==3) {
if (event.srcElement.tagName=="IMG"){
alert(clickmessage);
return false;
}
}
}
else if (document.layers) {
if (e.which == 3) {
alert(clickmessage);
return false;
}
}
else if (document.getElementById){
if (e.which==3&&e.target.tagName=="IMG"){
alert(clickmessage)
return false;
}
}
}

function associateimages(){
for(i=0;i<document.images.length;i++)
document.images[i].onmousedown=disableclick;
}

if (document.all)
document.onmousedown=disableclick
else if (document.getElementById)
document.onmouseup=disableclick
else if (document.layers)
associateimages()

///////////////////////////////////////////////////////////////////////////

// Hides Javascript Error Status
window.onerror=new Function("return true;");

// Disable text selecting and copy-paste functions.
// document.onselectstart=new Function("return false;");

// Disable drag & drop
// document.ondragstart=new Function("return false;");

// Disables showing URL of links in status bar. Overides All Set Messages To Default
// document.onmousemove=new Function("window.status='';");

///////////////////////////////////////////////////////////////////////////	
// activateActiveX - fixes click certain types of elements to activate before use.

if (navigator.appName == "Microsoft Internet Explorer") {
	
	//Array of elements to be replaced
	var arrElements = new Array(3);
	arrElements[0] = "object";
	arrElements[1] = "embed";
	arrElements[2] = "applet";
	
	//Loop over element types
	for (n = 0; n < arrElements.length; n++) {
	
		//set object for brevity
		replaceObj = document.getElementsByTagName(arrElements[n]);
		
		//loop over element objects returned
		for (i = 0; i < replaceObj.length; i++ ) {
		
			//set parent object for brevity
			parentObj = replaceObj[i].parentNode;
			
			//grab the html inside of the element before removing it from the DOM
			newHTML = parentObj.innerHTML;
			
			//remove element from the DOM
			parentObj.removeChild(replaceObj[i]);
			
			//stick the element right back in, but as a new object
			parentObj.innerHTML = newHTML;
		
			}
		}
	}

///////////////////////////////////////////////////////////////////////////	
// Form Submit Once /////

function submitonce(theform){
if (document.all||document.getElementById){
for (i=0;i<theform.length;i++){
var tempobj=theform.elements[i]
if(tempobj.type.toLowerCase()=="submit"||tempobj.type.toLowerCase()=="reset")
tempobj.disabled=true
}
}
}

///////////////////////////////////////////////////////////////////////////	
// Open Window /////

function resizeWin(newLoc, newWidth, newHeight) {
        newWin = open("",newLoc,"scrollbars=yes,margin=0,resizable=no,status=no,height=" + newHeight + ",width=" + newWidth);
}	

///////////////////////////////////////////////////////////////////////////	
//// Show / Hide Layers ////

function MM_findObj(n, d) { //v4.0
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 && document.getElementById) x=document.getElementById(n); return x;
}

function MM_showHideLayers() { //v3.0
var i,p,v,obj,args=MM_showHideLayers.arguments;
for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null)
{ v=args[i+2];
if (obj.style) { obj=obj.style;
v=(v=='show')?'visible':(v='hide')?'hidden':v; }
obj.visibility=v; }
}

///////////////////////////////////////////////////////////////////////////							
//-->

