Hi

I need to put value to an input hidden field, from a java script function.
I call the java script function from an onclick event of html:submit field
I have debuged that process and input hidden field does'nt take value.
Always have the default value.

This is my way to do this


*******This is the java script function*********
<script language="JavaScript">

  function actualizarCampoOcultoRest(forma, campo, valor)

  {

   document.forma.campo.value = valor;

 }

</script>



**********This is the call to the function java script********************

<html:submit styleClass="botones" property="btnEdicion"
onclick="actualizarCampoOcultoRest(gestionarListadoMonitoresEDHEPForm,
campoOcultoRestablecer, '1');">

    <logic:present name="idSeleccionado" scope="session"><bean:message key=
"boton.Actualizar"/></logic:present>

    <logic:notPresent name="idSeleccionado" scope="session"><bean:message
key="boton.Insertar"/></logic:notPresent>

</html:submit>

*********This is the input field***********

<html:hidden property="campoOcultoRestablecer"/>

*******In the ActionForm class i declared the input field like
this:****** private
int campoOcultoRestablecer;

Always have the default value, 0

if anybody could help me...

Thanks

Reply via email to