The onBlur event handler uses the following Event object properties.

type - this property indicates the type of event. 
target - this property indicates the object to which the event was originally sent.

In other words once inside doThis(type, target)

then...
function doThis(type, target)
{
    for (var i=0;i<document.theForm.elements.length;i++)
         if (target== document.theForm.elements[i])
         return i;
}
regards,
-Martin
----- Original Message ----- 
  From: [EMAIL PROTECTED] 
  To: [EMAIL PROTECTED] 
  Sent: Friday, May 28, 2004 12:25 AM
  Subject: how to send the 'index' to javascript function



  Hi, 
          This is my jsp. 
          <logic:iterate name="books" id="book" indexId="index"> 
                  <html:text name="book" property="title" indexed="true" 
onblur="doThis()"/> 
          </logic:iterate> 
          
          how to send the 'index' as input to 'doThis()' [javascript Function] 

  Thanks
  Subramaniam




------------------------------------------------------------------------------


  ---------------------------------------------------------------------
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to