On Wed, Apr 4, 2012 at 12:55 AM, jason <jason.novo...@gmail.com> wrote:
> This is weird... If I do something like this taken from
> http://wicket.apache.org/apidocs/1.4/org/apache/wicket/ajax/AjaxEventBehavior.html
>
> WebMarkupContainer div=new WebMarkupContainer("div");
>         div.setOutputMarkupId(true);
>         div.add(new AjaxEventBehavior("onclick") {
>             protected void onEvent(AjaxRequestTarget target) {
>                 System.out.println("ajax here!");
>             }
>         }
>
> <div wicket:id="div>Click me</div>
>
> it works fine. However, if I do something like this:
>
> <div class="calendar-box" wicket:id="calendarBox">
>                    <div class="calendar-date-label"></div>
>                    <div class="calendar-day-label"></div>
>                </div>
>
> calendarBox.add(new AjaxEventBehavior("onclick") {
>                @Override
>                protected void onEvent(AjaxRequestTarget target) {
>                    System.out.println("ajax here!");
>                }
>            });
>            calendarBox.add(new Label("monthYear", monthYear.format(date)));
>            calendarBox.add(new Label("day", dayFormat.format(date)));
>
> Then I get
>
> java.lang.ClassNotFoundException: undefined
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:190)

Paste the whole stacktrace.

>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/how-to-make-a-div-containing-ajax-link-clickable-tp4530016p4530444.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>



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

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to