Re: How do i get the id value dynamically in java script?

sthirunav <[email protected]>
Newsgroups gmane.comp.java.open-symphony.webwork
Message-ID <950794.1150297643385.JavaMail.os-j2ee@opensymphony01.managed.contegix.com>
This is the code i used to display the start date.. witha a text box and an icon for the date picker.. on click of the date picker icon i need to pass the dynamically generated of the corresponding textbox id..

in my case this.id will send the id of a href... but i  want to send the dynamically generated id of the textbox's id to the  script...

BTW that id="item_id_%{id}" is not generating the dynamic id... 

<ww:iterator id="arrSCSLAList" value="arrSCSLAList" status="rowstatus">
<tr>
  <ww:if test="#rowstatus.odd == true">

      <td class="listrow1" align="center" height="20"><ww:textfield name="'arlStartDate'" value="StartDate" theme="'simple'" cssStyle="'width:80px'" cssClass="'inputfields'" id="slaStartDateId"/>
      <a href="javascript:pop_month_calendar('','document.getElementById(\'slaStartDateId\')')"><img src="<%= request.getContextPath() %>/images/icon_calendar.gif"border="0" align="absmiddle"></a></td>
  </ww:if>
  <ww:else>

      <td class="listrow2" align="center" height="15"><ww:textfield name="'arlStartDate'" value="StartDate" theme="'simple' " cssStyle="'width:80px'" cssClass="'inputfields'" id="slaStartDateId"/>
      <a href="javascript:pop_month_calendar('','document.getElementById(\'slaStartDateId\')')"><img src="<%= request.getContextPath() %>/images/icon_calendar.gif"border="0" align="absmiddle"></a></td>
</ww:else>
</tr>
</ww:iterator>
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=34288&messageID=66773#66773

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.