
function class_doc()
	{
	}
	
//declare object finding function 
function get_all_id(strId)
	{
		return eval("document.all." + strId);
	}

function get_dom_id(strId)
	{
		return document.getElementById(strId);
	}

function get_layer_id(strId)
	{
		return eval("document.layers."+strId);
	}
function find_layer_id(strBase,strId)
	{
		//layers unavailible due to nesting.
		//same with Images?
	}
//declare image finding function 

function get_image_id(strId)
	{
		return document.images[strId];
	}

//declare property mod functions
function increment_net_x(objTarget,intX)
	{
		objTarget.style.left=intX;
		return objTarget.style.left;
	}
function increment_net_y(objTarget,intX)
	{
		if(!objTarget.style.top)
			{
			alert(objTarget.style.top);
			}
		objTarget.style.top=intY;
		return objTarget.style.top;
	}
function increment_y(objTarget,intY)
	{
		if(!objTarget.style.top)
			{
			alert(objTarget.style.top);
			}
		objTarget.style.top=intY;
		return objTarget.style.top;
	}
function increment_x(objTarget,intX)
	{
		objTarget.style.left=intX;
		return objTarget.style.left;
	}
//retrieve height
function get_dom_height(objTarget)
	{
		return objTarget.style.height;
	}
function get_net_height(objTarget)
	{
		//intHeight=objTarget.height;
		//return intHeight;
	}

//build object
switch(true)
{
	case Boolean(document.getElementById):
		class_doc.prototype.get_layer=get_dom_id;
		class_doc.prototype.get_img=get_dom_id;
		class_doc.prototype.move_x=increment_x;
		class_doc.prototype.move_y=increment_y;
		class_doc.prototype.get_height=get_dom_height;
	break;
	case Boolean(document.layers):
		class_doc.prototype.get_layer=get_layer_id;
		class_doc.prototype.get_img=get_image_id;
		class_doc.prototype.move_x=increment_net_x;
		class_doc.prototype.move_y=increment_net_y;
		class_doc.prototype.get_height=get_net_height;
	break;
	case Boolean(document.all):
		class_doc.prototype.get_layer=get_all_id;
		class_doc.prototype.get_img=get_all_id;
		class_doc.prototype.move_x=increment_x;
		class_doc.prototype.move_y=increment_y;
		class_doc.prototype.get_height=get_dom_height;
	break;
	
}
objDoc=new class_doc;//cross browser document object


