<!--

function invalid_user() {
setTimeout("window.location='./index.html'",3000); 

}

function checkform() {

desc = document.update.description.value;
alert (desc);
//if desc.length > 255 {
//	alert("Field length is limited to 255 characters for this demonstration");
//	return false;
//	}
return true;

}

function checkform() {
fname();
file = document.upload_images.uploadfile.value;
total_len = document.upload_images.uploadfile.value.length;
suffix = total_len - 3;
type = file.substring(suffix,total_len);
if (file == "") {
alert ("Please select file to upload.");
return false;
}
if ((type == "jpg") || (type == "gif")) {
return true;
}
else {
alert ("This file is not supported. Please use only gif or jpg images");
return false;
	}
}

function fname() {
file = document.upload_images.uploadfile.value;
total_len = document.upload_images.uploadfile.value.length;
sub1 = file.substring(70,80);

var x=0;
var slash = "";

	while ((x < total_len) && (slash !="\\")) {
		diff = total_len - x;
		slash = file.charAt(diff);
		x++;
		document.upload_images.filename.value = file.substring(diff+1,total_len);
	}
}

//-->


