function changeFontSize(inc) {

  var p = document.getElementsByTagName('p');
  for(n=0; n<p.length; n++) {
    if(p[n].style.fontSize) {
       var size = parseInt(p[n].style.fontSize.replace("px", ""));
    } else {
       var size = 12;
    }
    p[n].style.fontSize = size+inc + 'px';
   }
  
  var td = document.getElementsByTagName('td');
  for(n=0; n<td.length; n++) {
    if(td[n].style.fontSize) {
       var size = parseInt(td[n].style.fontSize.replace("px", ""));
    } else {
       var size = 12;
    }
    td[n].style.fontSize = size+inc + 'px';
   }
  
  /*var a = document.getElementsByTagName('a');
  for(n=0; n<a.length; n++) {
    if(a[n].style.fontSize) {
       var size = parseInt(a[n].style.fontSize.replace("px", ""));
    } else {
       var size = 12;
    }
    a[n].style.fontSize = size+inc + 'px';
   }*/
  
  var th = document.getElementsByTagName('th');
  for(n=0; n<th.length; n++) {
    if(th[n].style.fontSize) {
       var size = parseInt(th[n].style.fontSize.replace("px", ""));
    } else {
       var size = 12;
    }
    th[n].style.fontSize = size+inc + 'px';
   }
  
  var li = document.getElementsByTagName('li');
  for(n=0; n<li.length; n++) {
    if(li[n].style.fontSize) {
       var size = parseInt(li[n].style.fontSize.replace("px", ""));
    } else {
       var size = 12;
    }
    li[n].style.fontSize = size+inc + 'px';
   }    
}

defaultVal = 'Enter keyword';
function doSearch(frm) {
	with (document[frm]) {
		if(txtKeyword.value != defaultVal && txtKeyword.value) {
				submit();
		}
	}
	return false;
}

function doCart(action,id,price,size) {

	if (document.getElementById) {
		col = document.getElementById('cboColour'+id);
	} else if (document.all) {
		col = document.all['cboColour'+id];
	}

	if (col!=null) {
		col = col.options[col.options.selectedIndex].value;
	} else {
		col = "-1";
	}
	if (document.getElementById) {
		size = document.getElementById('cboSize'+id);
	} else if (document.all) {
		size = document.all['cboSize'+id];
	}

	if (size!=null) {
		size = size.options[size.options.selectedIndex].value;
	} else {
		size = "-1";
	}	
	if (action=='add') {
		self.location = '/cart/?action='+action+'&price='+price+'&id='+id+'&col='+col+'&size='+size;
	} else {
		self.location = '/cart/?action='+action;
	}
}

function printEmail(user,domain) {
	address = '<a href=\"mailto:' + user + '@' + domain + '\">' + user + '@' + domain + '<'+'/a>';
	document.write(address);
}

checkBrowser();
