function marker_class(inPid, inPnt, inCount, inAdr, inDsc, inIms, inIcT, inIcX, inIcY, inHid)
{
	this.uid   = inCount;			// 'unique id' position in the array of marker classes in map.markers[]
	this.pid   = inPid;       // 'point id' key id from the database for this record
	this.lat   = inPnt.lat(); // 'lattitude' of property
	this.lng   = inPnt.lng(); // 'longitude' of property
	this.adr   = inAdr;	// 'header' title text for the property
	this.dsc   = inDsc;	// 'description' of property
	this.icn   = inIcT + ".png";	// 'icon' image to use as a map marker icon
	this.ict   = inIcT; // 'icon type'
	this.tic   = inIcT + "_transparent.png"; // 'icon transparent' transparent icon (png version of inIcn at 1% opacity used for IE click compatability)
	this.icx   = inIcX; // 'icon width' width of icon
	this.icy   = inIcY; // 'icon height' height of icon
	this.pnt   = inPnt; //'point' new GLatLng(this.lat, this.lng);
	this.act   = "active"; // 'active' or inactive (inactive if the marker has been deleted from the map)
	this.ims   = inIms; // 'image status' default/temp/loaded
	this.img   = ""; // 'image' current image of the property
	this.ini   = "false"; // 'initialized' whether or not to refresh the image when the 'edit' button is clicked
	this.hid   = inHid;
	
	this.htmlWindow = "";
  
	this.createMarker = function()
  {
		
		var newIcon = new GIcon(); //G_DEFAULT_ICON
		newIcon.image = "./vn_icons/" + this.icn;
		newIcon.iconSize = new GSize(this.icx,this.icy); 
		newIcon.iconAnchor = new GPoint(this.icx/2+3,this.icy-1);
		newIcon.infoWindowAnchor = new GPoint(this.icx/2+3,this.icy);
		newIcon.transparent = "./vn_icons/" + this.tic;
		newIcon.printImage = "./vn_icons/" + this.icn;
		newIcon.mozPrintImage = "./vn_icons/" + this.icn;
		var markerOptions = { icon:newIcon, draggable:false };
		
		var marker = new GMarker(this.pnt, markerOptions);
		this.addMarkerClickListener(marker);
		marker.value = this.uid;

		return marker;
  }

	this.addMarkerClickListener = function(marker) 
	{
    this.htmlWindow = GEvent.addListener(marker, "click", function() 
    {	// FOLLOWING CODE OUTSIDE CLASS SCOPE //
    	var val = marker.value;

			// load the image if it has not yet been loaded
			if (map.markers[val].ini == "false")
			{
				map.markers[val].setImage();
				map.markers[val].ini = "true";
			}
			
			var url_part_one; 
			var url_part_two;
			
			if (map.markers[val].hid != "")
			{
				url_part_one = '<a href="/listings.php?hID=' + map.markers[val].hid + '">';
				url_part_two = "</a>"
			}
			else
			{
				url_part_one = "";
				url_part_two = "";
			}
			map.map.openInfoWindowHtml(map.markers[val].pnt,'<div style="width:240px;">' +
				'<strong>' + map.markers[val].adr + '</strong><br>' + 
				map.markers[val].dsc + '<br>' +
        '<br>' + url_part_one + '<img src="' + map.markers[val].img + '" style="height:80px;width:120px;" border=0>' + url_part_two + '<br><br>' +
				'</div>');
			// END OF OUTSIDE CLASS SCOPE
    });		
	}
	
  this.mkr = this.createMarker(this.pnt);
	
	this.refreshImage = function()
	{	
		this.setImage();
		document.images["propertyImg" + this.uid].src =  this.img; // Refresh image
	}
	
	this.setImage = function()
	{
		var imgPath = '/vn_images_dev/';
		
		var tempTime = new Date();
		tempTime = "?" + tempTime.getTime();
		
		if (this.ims=="default")
		{	imgPath += "noPhotoAvailable.jpg"; }
		else if (this.ims=="loaded")
		{	imgPath += "image_" + this.pid + "_vn.jpg"; }
		else if (this.ims=="temp")
		{	imgPath += "temp_" + this.uid + ".jpg"; }

		this.img = imgPath + tempTime;
	}
} // End class



















