 function sendmail() {
		if( document.form1.kat.value == "" ) {
		window.alert( 'You need to select a category.' );
		return false;}	
		if( document.form1.name.value == "" ) {
		window.alert( 'You need to fill in your name.' );
		return false;}			
		if( !document.form1.email.value || document.form1.email.value.replace( /[\w\-]+(\.[\w\-]+)*@[\w\-]+(\.[\w\-]+)+/i, "" ) ) {
		window.alert( 'You need to fill in your email address.' );
		return false;}
		if( document.form1.url.value == "" ) {
		window.alert( 'You need to fill in a url.' );
		return false;}
		var punkt = document.form1.url.value.indexOf('.');
		if (punkt == -1){
		window.alert( 'Oops, you did not fill in a proper URL (no dot). Please try again.' );
				return false;} 
		if( document.form1.title.value == "" ) {
		window.alert( 'You need to fill in a title.' );
		return false;}
		if(document.form1.title.value.length > 65) {
		window.alert( 'Plesase check your title. The field has a maximum of 65 characters.' );
		return false;}
		var storlek = document.form1.description.value.length;
		if(storlek < 4 & document.getElementById("textlink").checked==true) {
		window.alert( 'You have checked the radiobutton text link. Your text link must be at least 5 letters in length or uncheck the radiobutton.' );
		return false;}
		if(storlek > 4 & document.getElementById("textlink").checked==false) {
		window.alert( 'You have checked the radiobutton banner/image, but have specified a text link. Leave the text link field blank or check the text link radiobutton.' );
		return false;}
else
 var name = document.form1.name.value;
 var url = document.form1.url.value;
 var email = document.form1.email.value;
 var title = document.form1.title.value;
 		  title = title.split("?").join("%3F");
		  title = title.split("%").join("%25");
		  title = title.split("&").join("%26");
		  title = title.split(";").join("%3B");
		  title = title.split("=").join("%3D");
		  title = title.split("&").join("%26");
		  title = title.split('"').join("%22");
 var banner = "";
 		if(document.getElementById("banner").checked==true) {
		banner = "Don't forget to attach your banner/image. (maximum size: 120*60 width and height)%0A%0A";}
 var description = "";
 		if(document.getElementById("textlink").checked==true) {
		description = document.form1.description.value;		
		  description = description.split("?").join("%3F");
		  description = description.split("%").join("%25");
		  description = description.split("&").join("%26");
		  description = description.split(";").join("%3B");
		  description = description.split("=").join("%3D");
		  description = description.split("&").join("%26");
		  description = description.split('"').join("%22");	
		description = "Your text link: " + description + "%0A"; }
  var linker = "";
   		if(document.form1.linker.checked) {
		linker = "Link Exchange Partner: Yes%0A"; }
	var kat = document.form1.kat.value;
	kat = kat.split("&").join("%26"); 
  mailto = "advertise@surfwebtips.com"
  var email = "Surfwebtips reply and payment information will be sent to: "+email;
  var months = document.form1.months.value;
  var price = months*29;
  var brev = "mailto:"+mailto+"?subject=Advertise at Surfwebtips&body=%0A"+
  banner+"Hi, my name is "+name+
  " and I would like to advertise my web site at Surfwebtips.com%0A%0AMy advertisement information:%0ACategory section: "+
  kat+"%0ANumber of months: "+months+"%0AUSD: "+price+"%0A%0AWeb site: "+url+"%0ATitle: "+title+"%0A"+description+linker+"%0A%0A"+email+"%0A%0ABest regards,%0A"+name;
  mailwin = window.open(brev);
}
function Open7(){
	win=window.open("http://www.surfwebtips.com/linkexchangebox2.htm","myWin","height=200,width=700,toolbars=0,address=0,scrollbars=0");}
function Open8(){
		if( document.form1.kat.value == "" ) {
		window.alert( 'You need to select a category.' );
		return false;}	
		if( document.form1.name.value == "" ) {
		window.alert( 'You need to fill in your name.' );
		return false;}		
		if( !document.form1.email.value || document.form1.email.value.replace( /[\w\-]+(\.[\w\-]+)*@[\w\-]+(\.[\w\-]+)+/i, "" ) ) {
		window.alert( 'You need to fill in your email address.' );
		return false;}
		if( document.form1.url.value == "" ) {
		window.alert( 'You need to fill in a url.' );
		return false;}
		var punkt = document.form1.url.value.indexOf('.');
		if (punkt == -1){
		window.alert( 'Oops, you did not fill in a proper URL (no dot). Please try again.' );
		return false;} 
		if( document.form1.title.value == "" ) {
		window.alert( 'You need to fill in a title.' );
		return false;}
		if(document.form1.title.value.length > 65) {
		window.alert( 'Plesase check your title. The field has a maximum of 65 characters.' );
		return false;}
		var storlek = document.form1.description.value.length;
		if(storlek < 4 & document.getElementById("textlink").checked==true) {
		window.alert( 'You have checked the radiobutton text link. Your text link must be at least 5 letters in length or uncheck the radiobutton.' );
		return false;}
		if(storlek > 4 & document.getElementById("textlink").checked==false) {
		window.alert( 'You have checked the radiobutton banner/image, but have specified a text link. Leave the text link field blank or check the text link radiobutton.' );
		return false;}
else
 var name = document.form1.name.value;
 var url = document.form1.url.value;
 var email = document.form1.email.value;
 var title = document.form1.title.value;
 var banner = "";
 		if(document.getElementById("banner").checked==true) {
		banner = "Don't forget to <strong>attach</strong> your banner/image. (maximum size: 120*60 width and height)<br/><br/>";}
 	var description = "";
 		if(document.getElementById("textlink").checked==true) {
		description = document.form1.description.value;			
		description = "<strong>Your text link:</strong> " + description + "<br/>"; 	}
  	var linker = "";
   		if(document.form1.linker.checked) {
		linker = "<strong>Link Exchange Partner:</strong> Yes<br/>"; }
	var kat = document.form1.kat.value;
  mailto = "advertise@surfwebtips.com"
  var email = "Surfwebtips <strong>reply</strong> and payment information will be sent to: "+email;
  var months = document.form1.months.value;
  var price = months*29;
  var preview = "<strong>mailto:</strong> "+mailto+"<br/><strong>subject:</strong> Advertise at Surfwebtips<br/><br/>"+
  banner+"Hi, my name is "+name+
  " and I would like to advertise my web site at Surfwebtips.com<br/><br/>My advertisement information:<br/><strong>Category section:</strong> "+
  kat+"<br/><strong>Number of months:</strong> "+months+"<br/><strong>USD:</strong> "+price+"<br/><br/><strong>Web site:</strong> "+url+"<br/><strong>Title:</strong> "+title+"<br/>"+description+linker+"<br/><br/>"+email+"<br/><br/>Best regards,<br/>"+name;
		preview_window = open("","previewwindow","width=300,height=500,left=10,top=10,scrollbars");
		preview_window.document.open();
		preview_window.document.write("<html><head><title>Email us your request</title></head>");
		preview_window.document.write("<body bgcolor=\"#DBEAF5\">");
		preview_window.document.write("<br /><strong>Copy and paste this information into your email program:</strong>");
		preview_window.document.write("<br /><br />" + preview);
		preview_window.document.write("</body></html>");
		preview_window.document.close(); }
<!-- Original:  Ronnie T. Moore -->
<!-- Web Site:  The JavaScript Source -->
<!-- Dynamic 'fix' by: Nannette Thacker -->
<!-- Web Site: http://www.shiningstar.net -->
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function textCounter(field, countfield, maxlimit) {
if (field.value.length > maxlimit) // if too long...trim it!
field.value = field.value.substring(0, maxlimit);
// otherwise, update 'characters left' counter
else 
countfield.value = maxlimit - field.value.length;}