You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by SantiagoA <s....@gmx.de> on 2007/10/31 15:28:54 UTC
Problem with scriptaculous in wicket 1.3 beta3
Hi,
i try to use the Effect class of the scriptaculous jar in a testApp.
My Code:
Java:
import org.wicketstuff.scriptaculous.effect.Effect;
...
final StaticImage stimg = new StaticImage("fehler");
AjaxLink al = new AjaxLink("clickImg") {
private static final long serialVersionUID = 0L;
@Override
public void onClick(AjaxRequestTarget target) {
target.appendJavascript(new Effect.Fade(this).toJavascript());
}
};
form.add(al);
al.add(stimg);
...
HTML:
...
#
<div>
/pics/fehler_404_gross.jpeg
</div>
The Wicket Ajax Debug Window shows:
INFO: Response parsed. Now invoking steps...
ERROR: Exception evaluating javascript: ReferenceError: Effect is not
defined
INFO: Response processed successfully.
i´m using apache-wicket-1.3.0-beta3 and
wicketstuff-scriptaculous-1.3-20070924.212110-2.jar.
i tried also with wicket-contrib-scriptaculous-0.1.1.jar and
wicketstuff-scriptaculous-1.3-20070911.130143-1.jar
What am i doing wrong.
Can anyone help?
--
View this message in context: http://www.nabble.com/Problem-with-scriptaculous-in-wicket-1.3-beta3-tf4725430.html#a13510542
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Problem with scriptaculous in wicket 1.3 beta3
Posted by SantiagoA <s....@gmx.de>.
Thanks a lot,
that was the solution!
--
View this message in context: http://www.nabble.com/Problem-with-scriptaculous-in-wicket-1.3-beta3-tf4725430.html#a13511725
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Problem with scriptaculous in wicket 1.3 beta3
Posted by Ryan Sonnek <ry...@gmail.com>.
Yep,
you need to also do:
add(AbstractScriptaculousBehavior.newJavascriptBinding());
On 10/31/07, Ernesto Reinaldo Barreiro <re...@isencia.com> wrote:
>
> Probably your are missing a HeaderContributor adding the actual
> effects.js and prototype.js to your page? Just guessing...
>
> SantiagoA wrote:
> > Hi,
> > i try to use the Effect class of the scriptaculous jar in a testApp.
> >
> > My Code:
> > Java:
> > import org.wicketstuff.scriptaculous.effect.Effect;
> > ...
> > final StaticImage stimg = new StaticImage("fehler");
> > AjaxLink al = new AjaxLink("clickImg") {
> > private static final long serialVersionUID = 0L;
> >
> > @Override
> > public void onClick(AjaxRequestTarget target) {
> > target.appendJavascript(new Effect.Fade(this).toJavascript());
> > }
> > };
> > form.add(al);
> > al.add(stimg);
> > ...
> >
> > HTML:
> > ...
> > #
> > <div>
> > /pics/fehler_404_gross.jpeg
> > </div>
> >
> >
> > The Wicket Ajax Debug Window shows:
> > INFO: Response parsed. Now invoking steps...
> > ERROR: Exception evaluating javascript: ReferenceError: Effect is not
> > defined
> > INFO: Response processed successfully.
> >
> > i´m using apache-wicket-1.3.0-beta3 and
> > wicketstuff-scriptaculous-1.3-20070924.212110-2.jar.
> > i tried also with wicket-contrib-scriptaculous-0.1.1.jar and
> > wicketstuff-scriptaculous-1.3-20070911.130143-1.jar
> >
> > What am i doing wrong.
> > Can anyone help?
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Re: Problem with scriptaculous in wicket 1.3 beta3
Posted by Ernesto Reinaldo Barreiro <re...@isencia.com>.
Probably your are missing a HeaderContributor adding the actual
effects.js and prototype.js to your page? Just guessing...
SantiagoA wrote:
> Hi,
> i try to use the Effect class of the scriptaculous jar in a testApp.
>
> My Code:
> Java:
> import org.wicketstuff.scriptaculous.effect.Effect;
> ...
> final StaticImage stimg = new StaticImage("fehler");
> AjaxLink al = new AjaxLink("clickImg") {
> private static final long serialVersionUID = 0L;
>
> @Override
> public void onClick(AjaxRequestTarget target) {
> target.appendJavascript(new Effect.Fade(this).toJavascript());
> }
> };
> form.add(al);
> al.add(stimg);
> ...
>
> HTML:
> ...
> #
> <div>
> /pics/fehler_404_gross.jpeg
> </div>
>
>
> The Wicket Ajax Debug Window shows:
> INFO: Response parsed. Now invoking steps...
> ERROR: Exception evaluating javascript: ReferenceError: Effect is not
> defined
> INFO: Response processed successfully.
>
> i´m using apache-wicket-1.3.0-beta3 and
> wicketstuff-scriptaculous-1.3-20070924.212110-2.jar.
> i tried also with wicket-contrib-scriptaculous-0.1.1.jar and
> wicketstuff-scriptaculous-1.3-20070911.130143-1.jar
>
> What am i doing wrong.
> Can anyone help?
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Problem with scriptaculous in wicket 1.3 beta3
Posted by SantiagoA <s....@gmx.de>.
Excuse me the HTML should look like:
...
<a href="#" wicket:id="clickImg">
<div>
<img wicket:id="fehler" src="/pics/fehler_404_gross.jpeg" border="none"
/>
</div>
</a>
--
View this message in context: http://www.nabble.com/Problem-with-scriptaculous-in-wicket-1.3-beta3-tf4725430.html#a13510547
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org