validate number of textarea

Javascript coding ..

Moderators: macek, egami, gesf

Post Reply
New php-forum User
New php-forum User
Posts: 37
Joined: Wed Jun 20, 2012 3:20 am

validate number of textarea

Post by lvidya » Wed Jun 27, 2012 1:18 am

$("[name=saveAnswer]").click(function() {

var inputs = document.getElementsByTagName("textarea");
var length=inputs.length;
var i;
for(i=0; i<length; i++)



Plz help in number of textareas

User avatar
php-forum Fan User
php-forum Fan User
Posts: 981
Joined: Thu Feb 17, 2011 6:52 am
Location: Racine, WI

Re: validate number of textarea

Post by Nullsig » Wed Jun 27, 2012 6:11 am

if(inputs.value == ''){
alert('One or more text box is not filled in');

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest