Hi,

The produced <a ...> looks OK. Clicking on it should execute the
script in onclick.
Try with a different browser. Maybe JavaScript is disabled at the one
you use...

On Mon, Feb 20, 2012 at 11:12 PM, Richard W. Adams <[email protected]> wrote:
> Hmmmmm.. more mystery. I put a break point on wicketAjaxGet. But it never
> gets executed. Clicking the link, apparently does absolutely nothing.
> Doesn't even cause the Javascript to be called.
>
> Anyone have any ideas?
>
>
>
> From:   Andrea Del Bene <[email protected]>
> To:     [email protected]
> Date:   02/19/2012 07:26 AM
> Subject:        Re: AjaxLink.onClick() Not Triggered
>
>
>
> Hi,
>
>  at first glance I can't say what's wrong with your code, but you
> should try debugging wicketAjaxGet function with FireBug or some other
> dev tool. In this way you should find why there's no AJAX call.
>> I have an Ajax link in a drop down menu, created like this:
>>
>>                  final MenuChoice item = new MenuChoice("Delete") {
>>                          private static final long serialVersionUID =
> 1L;
>>
>>                          @Override protected AbstractLink newLink(final
>> String id) {
>>                                  final AjaxLink<String>  link = new
>> AjaxLink<String>(id) {
>>                                          private static final long
>> serialVersionUID = 1L;
>>                                          @Override public void
>>                                          onClick(final AjaxRequestTarget
>> target) {
>>   confirmer.confirm(model.getTrack(), target);
>>                                          }
>>                                  };
>>                                  return link;
>>                          }
>>                  };
>>
>> The generated HTML looks like this:
>>
>> <a href="#" id="id28" onclick="var
>>
> wcall=wicketAjaxGet('?wicket:interface=:1:resultForm:track-list:gridViewportContainer:viewPortTable:dataGridBody:rows:2:cells:12:cell:smartMenu:menuItemRepeater:5:menuItem:labelContainer:menuLink:1:IBehaviorListener:0:',function()
>> { }.bind(this),function() { }.bind(this), function() {return
>> Wicket.$('id28') != null;}.bind(this));return !wcall;">Delete</a>
>>
>> However, when I click the link, the onClick() handler is not called. The
>> Wicket Ajax debug window shows no Ajax activity occurring.
>>
>> Can anyone see what I'm doing wrong?
>>
>> **
>>
>> This email and any attachments may contain information that is
> confidential and/or privileged for the sole use of the intended recipient.
>  Any use, review, disclosure, copying, distribution or reliance by others,
> and any forwarding of this email or its contents, without the express
> permission of the sender is strictly prohibited by law.  If you are not
> the intended recipient, please contact the sender immediately, delete the
> e-mail and destroy all copies.
>> **
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
>
>
> **
>
> This email and any attachments may contain information that is confidential 
> and/or privileged for the sole use of the intended recipient.  Any use, 
> review, disclosure, copying, distribution or reliance by others, and any 
> forwarding of this email or its contents, without the express permission of 
> the sender is strictly prohibited by law.  If you are not the intended 
> recipient, please contact the sender immediately, delete the e-mail and 
> destroy all copies.
> **



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to