Hi,

in the past we did it in this way that we looking for the element only in
the affected form.
So in the form there is only one element with the id javax.faces.ViewState.
It is also necessary that every form contains a hidden field with this id.
So for JSF ok but it breaks the w3c standard and you can't use
document.getElementById.
We've got a appropriate code snippet in the j4fry code.


2009/4/19 Ganesh <[email protected]>

> Hi Werner,
>
> 2 elements with the same id truely brake the HTML standard. And it's true,
> with Mojarra 2.0 and 2 forms on a page I get 2 identical
> <input id="javax.faces.ViewState" type="hidden" value="j_id1:j_id2"
> name="javax.faces.ViewState"/>
> elements!
>
> Still, I'm not able to find this in the specs, can you please point me to
> the section you are referring to?
>
>> The spec says that an element with the identifier javax.faces.ViewState
>> has to be added to every form if it does not exist within the update phase
>> if viewState itself is responded!
>>
>
> Best Regards,
> Ganesh
>



-- 
Mit freundlichen Grüßen / Kind regards
Alexander Bell

J4Fry OpenSource Community
Internet: http://www.j4fry.org
E-Mail: [email protected]
Webprofil: http://www.j4fry.org/alexanderbell.shtml

Reply via email to