function clearText(thefield) {
  if (thefield.defaultValue==thefield.value) { thefield.value = "" }
} 
function replaceText(thefield) {
  if (thefield.value=="") { thefield.value = thefield.defaultValue }
}


function link_show(d,a)
{
	 document.getElementById(d).style.display='block';
	// document.getElementById(a).src='images/admin_ro.jpg';
	 
}
function link_hide(d,a)
{
	 document.getElementById(d).style.display='none';
	// document.getElementById(a).src='images/admin.jpg';
	 
}

function link_showF(b,c)
{
	 document.getElementById(b).style.display='block';
	// document.getElementById(c).src='images/product_photos_ro.jpg';
	 
}
function link_hideF(b,c)
{
	 document.getElementById(b).style.display='none';
	// document.getElementById(c).src='images/product_photos.jpg';
	 
}

function top_show(d,a)
{
	 document.getElementById(d).style.display='block';
	 
}
function top_hide(d,a)
{
	 document.getElementById(d).style.display='none';
}

function checkExpressDownload(id) {
	if(id == '1') { 
		document.getElementById('exprsdwn').style.display = 'block';	
		document.getElementById('brand_hide_show').style.display = 'none';	
	} else { 
		document.getElementById('exprsdwn').style.display = 'none';	
		document.getElementById('brand_hide_show').style.display = 'block';	
	}
}

function checkPhotoType(id)
{  
	  $.ajax({
	   type: "POST",
	   url: "get_category_for_upload.php",
	   data: "&id="+escape(id),
	   success: function(response){
		if(id != '1') {
			$('#brand_hide_show').show();
			$('#exprsdwn').hide();
		}
		$('#category_type_dropdown').html(response);
	   }
	});
}

