tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From SakshiAgarwal <sakshi.a...@gmail.com>
Subject Invoke Javascript using LinkSubmit
Date Wed, 16 Jun 2010 14:12:00 GMT

Hi,

i have used multiple options to invoke javascript on clicking linkSubmit,
but none works, although they all work with Submit.
a) Invoking javascript from tml page as follows:
 <script>
  function extraStep() {
    alert("ENTER extraStep");   
  }
</script> 
 <t:loop source="photoDetails" value="each"> -${each.title}  <br />    	
       	<t:form t:id="formId" id="formId"><p>
    	<t:label for="reportedCategory"/>  <t:select t:id="reportedCategory"
t:label="Reported Category"/></p>
    	[<t:actionlink t:id="approvePhotos">Approve</t:actionlink>]
          	 <input type="hidden" id="photoObject" value="${each}" />
    	<t:submit t:id="disapprovePhoto" value="Disapprove Photo" 
onclick="extraStep();"></t:submit>
      	 </t:form>       	 
       	 </t:loop>    	
** This works with Submit but not with linkSubmit
b) tried using mixins, but didnt work with LinkSubmit
c) tried using JSON, but that also didnt work with LinkSubmit. afterRender()
does not get invoked.
onSuccess(),onSelectedFromDisapprovePhoto() methods are not invoked from
Linksubmit.

Can someone please advise how can I use LinkSubmit in order to invoke
javascript.
Looking forward for an early response.

regards
sakshi
-- 
View this message in context: http://old.nabble.com/Invoke-Javascript-using-LinkSubmit-tp28903316p28903316.html
Sent from the Tapestry - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


Mime
View raw message