function PreventClickInEmptyDiv()
{
	for (var i = 1; i < NUM_IMGS + 1; i++)
	{
		var id = "d";
		var num = i.toString();
		id = id.concat(num);
		var div = document.getElementById(id);
		
		//check to see if it has an image
		if (/.*<img.*/.test(div.innerHTML) === false)
		{
			//if not, don't allow that area to be clicked to prevent
			//weird dragging bug
			div.addEventListener('mousedown', function(ev){
				ev.preventDefault();
			}, false);
		}
	}
}
//Doesn't allow the  user to click where the old img was located
Doesn't allow the  user to click where the old img was located
Doesn ' t allow the user to click where the old img was located
function PreventClickInEmptyDiv()
{
	for (var i = 1; i < NUM_IMGS + 1; i++)
	{
		var id = "d";
		var num = i.toString();
		id = id.concat(num);
		var div = document.getElementById(id);
		if (/.*<img.*/.test(div.innerHTML) === false)
		{
			div.addEventListener('mousedown', function(ev){
				ev.preventDefault();
			}, false);
		}
	}
}
function PreventClickInEmptyDiv ( ) { for ( var i = 1 ; i < NUM_IMGS + 1 ; i ++ ) { var id = "d" ; var num = i . toString ( ) ; id = id . concat ( num ) ; var div = document . getElementById ( id ) ; if ( / .*<img.* / . test ( div . innerHTML ) === false ) { div . addEventListener ( 'mousedown' , function ( ev ) { ev . preventDefault ( ) ; } , false ) ; } } }
Doesn't allow the  user to click where the old img was located
Doesn ' t allow the user to click where the old img was located
//check to see if it has an image //if not, don't allow that area to be clicked to prevent //weird dragging bug