Pedro Duarte
Pedro Duarte

Reputation: 21

Struts 1 submit only works in IE

I have some input fields that are created dynamically using JS. The thing is, when I submit the page, the setters of the Bean are not called, except when using IE. It only works on Chrome and Firefox when I add the input fields statically on the code.

This works on all browsers:

<input name="test" value="test"/>

This only works in IE:

var test = document.createElement('input');
test.name = 'test';
test.value = 'test';
tbody.appendChild(test);

Anyone know the solution, please?

Upvotes: 1

Views: 574

Answers (3)

Pedro Duarte
Pedro Duarte

Reputation: 21

It was my mistake. The form tag was inside my table tag.

Upvotes: 1

Alisson Alvarenga
Alisson Alvarenga

Reputation: 658

This guy had the same problem:

http://forums.mozillazine.org/viewtopic.php?f=25&t=518697&p=2742491

Try using html:rewrite to add new inputs.

Upvotes: 1

epascarello
epascarello

Reputation: 207527

If that is a tbody element of a table as the variable name suggests, that is invalid markup. tbody can only have rows as a child.

Upvotes: 0

Related Questions