function DivMaker(id,RefLay) {
// NETSCAPE
	if (is.ns) {
		if (is.ns4) {
			this.css = (RefLay)? eval("document."+RefLay+".document."+id) : document.layers[id]
			this.elm = this.event = this.css
			this.doc = this.css.document 
		}

		else if (is.ns5) {
			this.elm = document.getElementById(id)
			this.css = this.elm.style
			this.doc = document 
		}

		this.x = this.css.left
		this.y = this.css.top
		this.w = this.css.clip.width
		this.h = this.css.clip.height
	}

// MSIE
	else if (is.ie) {
		this.elm = this.event = document.all[id]
		this.css = document.all[id].style
		this.doc = document
		this.x = this.elm.offsetLeft
		this.y = this.elm.offsetTop
		this.w = this.elm.offsetWidth
		this.h = this.elm.offsetHeight 
		}
//ALL
this.id = id
}
/////////////////////////////////////////////////////////////////////////////////// END FUNCTION

function DivMakerMoveTo(x,y) {
	if (x!=null) {
		this.x = x
		if (is.ns) this.css.left = this.x
		else this.css.pixelLeft = this.x
	}
	if (y!=null) {
		this.y = y
		if (is.ns) this.css.top = this.y
		else this.css.pixelTop = this.y
	}
}
function DivMakerMoveBy(x,y) {
	this.moveTo(this.x+x,this.y+y)
}
function DivMakerShow() {
	this.css.visibility = (is.ns4)? "show" : "visible"
}

DivMaker.prototype.moveTo = DivMakerMoveTo
DivMaker.prototype.moveBy = DivMakerMoveBy
DivMaker.prototype.show = DivMakerShow

// BrowserCheck Object
function BrowserCheck() {
	var b = navigator.appName
	if (b=="Netscape") this.b = "ns"
	else if (b=="Microsoft Internet Explorer") this.b = "ie"
	else this.b = b
	this.version = navigator.appVersion
	this.v = parseInt(this.version)
	this.ns = (this.b=="ns" && this.v>=4)
	this.ns4 = (this.b=="ns" && this.v==4)
	this.ns5 = (this.b=="ns" && this.v==5)
	this.ie = (this.b=="ie" && this.v>=4)
	this.ie4 = (this.version.indexOf('MSIE 4')>0)
	this.ie5 = (this.version.indexOf('MSIE 5')>0)
	this.min = (this.ns||this.ie)
}
is = new BrowserCheck()
