You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by saty <sa...@gmail.com> on 2012/11/12 23:39:08 UTC

how do you pass load=effects to scriptaculous.js

in wicket 6.

using the below code, not sure how to pass the arguments as is done by the
current code (wicket 1.4)

JSLib.getHeaderContribution(VersionDescriptor.alwaysLatest(Library.SCRIPTACULOUS)).renderHead(response)

Thanks




--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-do-you-pass-load-effects-to-scriptaculous-js-tp4653797.html
Sent from the Users forum 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: how do you pass load=effects to scriptaculous.js

Posted by saty <sa...@gmail.com>.
Thanks, this is helpful.



--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-do-you-pass-load-effects-to-scriptaculous-js-tp4653797p4653841.html
Sent from the Users forum 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: how do you pass load=effects to scriptaculous.js

Posted by Martin Grigorov <mg...@apache.org>.
On Tue, Nov 13, 2012 at 5:13 PM, saty <sa...@gmail.com> wrote:

> Thanks for responding, To use SCRIPTACULOUS js libraries:
>
> We are using in maven:
>
>      <dependency>
>         <groupId>org.wicketstuff</groupId>
>         <artifactId>wicketstuff-jslibraries</artifactId>
>         <version>1.5.8</version>
>

You better use 6.2.0 as your Wicket version.


>      </dependency>
>
> And than code like this
>   @Override
>   public void renderHead(Component component, IHeaderResponse response)
>   {
>
>
> JSLib.getHeaderContribution(VersionDescriptor.alwaysLatest(Library.SCRIPTACULOUS)).renderHead(response)
>

As I said this is not Wicket API.


>   }
>
> scriptaculous.js documentation says:
>
> By default, scriptaculous.js loads all of the other javascript files
> necessary for effects, drag-and-drop, sliders, and all of the other
> script.aculo.us features. If you don’t need all of the features, you can
> limit the additional scripts that get loaded by specifying them in a
> comma-separated list, e.g.:
>
>
>
> So my question is how in wicket i will achieve this passing =>
> ?load=effects,dragdrop
> to scriptaculous.js
>

With plain Wicket:
PageParameters params = new PageParameters();
params.set("load", "effects,dragdrop");
response.render(JavaScriptHeaderItem.forReference(new
JavaScriptResourceReference(Scriptaculous.class, "scriptaculous.js"),
params))


>
> Thanks
>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/how-do-you-pass-load-effects-to-scriptaculous-js-tp4653797p4653833.html
> Sent from the Users forum 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
>
>


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

Re: how do you pass load=effects to scriptaculous.js

Posted by saty <sa...@gmail.com>.
Thanks for responding, To use SCRIPTACULOUS js libraries:

We are using in maven:

     <dependency>
	<groupId>org.wicketstuff</groupId>
	<artifactId>wicketstuff-jslibraries</artifactId>
	<version>1.5.8</version>
     </dependency>

And than code like this
  @Override
  public void renderHead(Component component, IHeaderResponse response)
  {
   
JSLib.getHeaderContribution(VersionDescriptor.alwaysLatest(Library.SCRIPTACULOUS)).renderHead(response)
  }

scriptaculous.js documentation says:

By default, scriptaculous.js loads all of the other javascript files
necessary for effects, drag-and-drop, sliders, and all of the other
script.aculo.us features. If you don’t need all of the features, you can
limit the additional scripts that get loaded by specifying them in a
comma-separated list, e.g.:



So my question is how in wicket i will achieve this passing =>
?load=effects,dragdrop
to scriptaculous.js

Thanks




--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-do-you-pass-load-effects-to-scriptaculous-js-tp4653797p4653833.html
Sent from the Users forum 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: how do you pass load=effects to scriptaculous.js

Posted by Martin Grigorov <mg...@apache.org>.
Hi,

Can you be more specific in your question ?
What exactly is the problem  ? Is there a compile error or runtime one ?
 This code is not part of Wicket core and it is not easy to find the
problem by just looking at this line.


On Tue, Nov 13, 2012 at 12:39 AM, saty <sa...@gmail.com> wrote:

> in wicket 6.
>
> using the below code, not sure how to pass the arguments as is done by the
> current code (wicket 1.4)
>
>
> JSLib.getHeaderContribution(VersionDescriptor.alwaysLatest(Library.SCRIPTACULOUS)).renderHead(response)
>
> Thanks
>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/how-do-you-pass-load-effects-to-scriptaculous-js-tp4653797.html
> Sent from the Users forum 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
>
>


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