Hi Josh,
Thanks, it works, so method should be declared as
OnDeleteConfirm, then createActionLink("DeleteConfirm",...)
A.C.
Josh Canfield-2 wrote:
>
>>
>>
>> >
>> > resources.createActionLink("onActionFromDeleteConfirm", false,
>> > id).toURI();
>>
>>
>> The action you are invoking is "deleteConfirm", the event method is
>> "onActionFromDeleteConfirm" so your action link should look like this:
>>
>
> Actually, I take that back. Your event method should be onDeleteConfirm.
> You
> aren't creating it from the action component so the "ActionFrom" part is
> not
> used.
>
> Josh
>
>
> On 11/1/07, Josh Canfield <[EMAIL PROTECTED]> wrote:
>>
>> resources.createActionLink("onActionFromDeleteConfirm", false,
>> > id).toURI();
>>
>>
>> The action you are invoking is "deleteConfirm", the event method is
>> "onActionFromDeleteConfirm" so your action link should look like this:
>>
>> resources.createActionLink("deleteConfirm", false, id).toURI();
>>
>> Josh
>>
>> On 11/1/07, Angelo Chen <[EMAIL PROTECTED]> wrote:
>> >
>> >
>> > Hi,
>> >
>> > I have a page which generate a link to an action in the same page, the
>> > link
>> > was embedded in a Streamresponse, when I click the link in the browser,
>> > it
>> > does not activate the action link created, why?
>> >
>> > Here is the code:
>> >
>> > public class TestPage2 {
>> >
>> > @Inject
>> > private ComponentResources resources;
>> >
>> > public StreamResponse onActionFromDelete(Long id) {
>> > String link1 =
>> > resources.createActionLink("onActionFromDeleteConfirm", false,
>> > id).toURI();
>> > return new TextStreamResponse("text/html", String.format("< a
>> > href='%s'>Confirm ", link1));
>> > }
>> >
>> > public String onActionFromDeleteConfirm(Long id) {
>> > System.out.println("delete confirm");
>> > return null;
>> > }
>> > }
>> >
>> > html xmlns:t=" http://tapestry.apache.org/schema/tapestry_5_0_0.xsd">
>> > <head>
>> > <title>Start Page</title>
>> > </head>
>> > <body>
>> > <h1>Test Page</h1>
>> > <t:actionLink t:id="Delete" context="1">Delete</t:actionLink><br/>
>> > </body>
>> > </html>
>> >
>> >
>> >
>> > --
>> > View this message in context:
>> http://www.nabble.com/T5%3A-actionlink-in-another-page-class-tf4730427.html#a13526220
>> >
>> > Sent from the Tapestry - User mailing list archive at
>> Nabble.com<http://nabble.com/>
>> > .
>> >
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>>
>>
>> --
>> --
>> TheDailyTube.com. Sign up and get the best new videos on the internet
>> delivered fresh to your inbox.
>
>
>
>
> --
> --
> TheDailyTube.com. Sign up and get the best new videos on the internet
> delivered fresh to your inbox.
>
>
--
View this message in context:
http://www.nabble.com/T5%3A-actionlink-in-another-page-class-tf4730427.html#a13539594
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]