Daniel,

Thanks for that. I was browsing the link_to_function, what it states is that
this tag is useful for triggering javascript functions, essentially what I
have looks like this:

link_to_function('Click here' , 'javascript:function()');

This renders itself in HTML format as:

<a onclick=" javascript function(); return false; " href="#">Click here</a>

So I get the point you are stating, that is by giving a distinct parameter
in the subaction (one sec, what exactly do u mean by subaction). But this
can't happen in link_to_function as the href is tailored to # in this case,
the onclick is stated to return false, once the javascript occurs.

If you meant the link_to tag, then in that case it might work, but I believe
you were illustrating the link_to_function jscript tag. Do let me know.,

regards,

parijat


On Mon, Aug 16, 2010 at 4:42 PM, Daniel Lohse
<[email protected]>wrote:

> Give each of them a distinct parameter "subaction" like in
> "module/action?subaction=bla" as the URL and change the "bla" with your
> separate events. As these URLs will never be seen by the user you can safely
> do that – even in symfony-land. ;-)
>
> Cheers, Daniel
>
> PS: If you're using link_to, careful to use the option array('query_string'
> => array('subaction' => 'bla')) notation as GET parameters are not
> permissible in the URL part of the link_to function (this is explained in
> the API documentation).
>
> On 17.08.2010, at 01:30, Parijat Kalia wrote:
>
> Hey guys,
>
> We know that the link_to_function can be used to trigger javascripts and
> the page posts back to itself. Correct me if I am wrong here. I have
> multiple link_to_function tags in my webpage. Is there a way I can detect
> which one was clicked once the post occurs. This is because, each of these
> link_to_function tags are meant to trigger separate events, that run only
> upon postback.
>
> Regards,
>
> Parijat Kalia
>
> --
> If you want to report a vulnerability issue on symfony, please send it to
> security at symfony-project.com
>
> You received this message because you are subscribed to the Google
> Groups "symfony users" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/symfony-users?hl=en
>
>
>  --
> If you want to report a vulnerability issue on symfony, please send it to
> security at symfony-project.com
>
> You received this message because you are subscribed to the Google
> Groups "symfony users" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<symfony-users%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/symfony-users?hl=en
>

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to