i'm still a newbie in javascript. i know this question may be silly for some experts in javascript. and i'm sorry for that :(

i want to create a dynamic form using javascript, where i can click a button to add some new fields. i tried to search it in google, and i tried to use it. but it doesn't work in mozilla and gave error warning in IE. can someone help me in creating that dynamic form, or maybe you can give me some links that give explanation about that.

thx so much,
AG

i'm still a newbie in javascript. i know this question may be silly for some experts in javascript. and i'm sorry for that :(

i want to create a dynamic form using javascript, where i can click a button to add some new fields. i tried to search it in google, and i tried to use it. but it doesn't work in mozilla and gave error warning in IE. can someone help me in creating that dynamic form, or maybe you can give me some links that give explanation about that.

thx so much,
AG

This is the example of to add the rows dynamically

for the first, it worked in IE with some alerts and didn't work in mozilla. but after i erase the loop in the middle, it works in mozilla and in IE with no alerts. is it okay? here is the code that i erased

for(var j=0; j<tbody.rows[i].childNodes.length; j++)
		{
			alert(">>"+tbody.rows[i].childNodes[j].getAttribute("Name")+">>");
			//tbody.rows[i].childNodes[j].setAttribute('name',new_name);
    	}

for the first, it worked in IE with some alerts and didn't work in mozilla. but after i erase the loop in the middle, it works in mozilla and in IE with no alerts. is it okay? here is the code that i erased

for(var j=0; j<tbody.rows[i].childNodes.length; j++)
		{
			alert(">>"+tbody.rows[i].childNodes[j].getAttribute("Name")+">>");
			//tbody.rows[i].childNodes[j].setAttribute('name',new_name);
    	}

erase, you mean commented.Actually you should comment that alert line, instead of that code.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.