RE: Wicket jQuery UI - Spinner for time

2015-12-30 Thread Ephraim Rosenfeld
Hello Sebastien:

I've created the request: https://github.com/sebfz1/wicket-jquery-ui/issues/217.

Thanks so much for following up and for your contributions to the development 
community.

Regards,

- Ephraim

-Original Message-
From: Sebastien [mailto:seb...@gmail.com] 
Sent: Wednesday, December 30, 2015 11:22 AM
To: users@wicket.apache.org
Subject: Re: Wicket jQuery UI - Spinner for time

Hi Ephraim,

The jQuery UI timespinner is not just matter of configuration, is a new widget 
extending from the spinner; that's why it's not straightforward to make it work.
I think it make sense to add it to the library, so please fill an issue:
https://github.com/sebfz1/wicket-jquery-ui/issues

I am already working on it, so it can be quick...

Thanks & best regards,
Sebastien.


On Wed, Dec 30, 2015 at 12:31 PM, Ephraim Rosenfeld 
wrote:

> Hello Wicket Team:
>
> I would like to use the Wicket jQuery UI "Spinner" widget, as shown here:
> http://www.7thweb.net/wicket-jquery-ui/spinner/DefaultSpinnerPage?0, 
> for a time field, like this example:
> https://jqueryui.com/resources/demos/spinner/time.html. This example 
> adds some additional jQuery Widget Factory code to override the 
> default functionality to format a date into a time field, e.g. '11:47 
> AM', and likewise, to parse new input back into a date.
>
> Is this possible to do via Wicket? Adding the additional jQuery Widget 
> Factory code in the example above did not seem to do the trick.
>
> I was thinking of using Ajax to update the component on the "onspin"
> event, which gets fired when one of the spinner arrow buttons are 
> pressed; however, I have no indication as to whether the value should 
> be incremented or decremented. Capturing the event on the "onspinstop" 
> event is sort of too late, because at this point, the widget already 
> gets populated with the integer value as determined by the arrow buttons.
>
> The jQuery UI documentation here (
> http://api.jqueryui.com/spinner/#event-spin<
> http://api.jqueryui.com/spinner/%23event-spin>) states that the input 
> can be obtained on the "onspin" event using the "ui.value" property, 
> and this can be used to determine whether the value in the field is to 
> be incremented/decremented. Is this property exposed on the Java layer 
> via Wicket?
>
> I am using Wicket version 6.15.
>
> Thank you in advance,
>
> - Ephraim
>


Re: Wicket jQuery UI - Spinner for time

2015-12-30 Thread Sebastien
Hi Ephraim,

The jQuery UI timespinner is not just matter of configuration, is a new
widget extending from the spinner; that's why it's not straightforward to
make it work.
I think it make sense to add it to the library, so please fill an issue:
https://github.com/sebfz1/wicket-jquery-ui/issues

I am already working on it, so it can be quick...

Thanks & best regards,
Sebastien.


On Wed, Dec 30, 2015 at 12:31 PM, Ephraim Rosenfeld 
wrote:

> Hello Wicket Team:
>
> I would like to use the Wicket jQuery UI "Spinner" widget, as shown here:
> http://www.7thweb.net/wicket-jquery-ui/spinner/DefaultSpinnerPage?0, for
> a time field, like this example:
> https://jqueryui.com/resources/demos/spinner/time.html. This example adds
> some additional jQuery Widget Factory code to override the default
> functionality to format a date into a time field, e.g. '11:47 AM', and
> likewise, to parse new input back into a date.
>
> Is this possible to do via Wicket? Adding the additional jQuery Widget
> Factory code in the example above did not seem to do the trick.
>
> I was thinking of using Ajax to update the component on the "onspin"
> event, which gets fired when one of the spinner arrow buttons are pressed;
> however, I have no indication as to whether the value should be incremented
> or decremented. Capturing the event on the "onspinstop" event is sort of
> too late, because at this point, the widget already gets populated with the
> integer value as determined by the arrow buttons.
>
> The jQuery UI documentation here (
> http://api.jqueryui.com/spinner/#event-spin<
> http://api.jqueryui.com/spinner/%23event-spin>) states that the input can
> be obtained on the "onspin" event using the "ui.value" property, and this
> can be used to determine whether the value in the field is to be
> incremented/decremented. Is this property exposed on the Java layer via
> Wicket?
>
> I am using Wicket version 6.15.
>
> Thank you in advance,
>
> - Ephraim
>


Security Issue or incorrect usage?

2015-12-30 Thread Илья Нарыжный
Guys,

Please advise on the following "feature".
There is the following cool ability in wicket:
https://cwiki.apache.org/confluence/display/WICKET/Dynamically+Generate+a+CSS+Stylesheet

Pretty much the same approach can be used for JavaScript.

But it's noted: if try to retrieve URL for dynamically generated CSS
or JS after initial load of it by "legal" use - you will receive file
with substituted parameters for first user.

Is it security issue or just incorrect usage of this feature?

Thanks,

Ilya

-
Orienteer(http://orienteer.org) - Modern Data Warehouse for your business.

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



Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Ernesto Reinaldo Barreiro
Thanks to you both for helping keep wicket alive and kicking!

On Wed, Dec 30, 2015 at 9:13 AM, Martin Grigorov 
wrote:

> Thank you, Ernesto!
> On Dec 30, 2015 10:12 AM, "Ernesto Reinaldo Barreiro" 
> wrote:
>
> > Thanks for your replay. I will roll out such an implementation and
> create a
> > PR against wicket-bootstrap
> >
> > On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
> > tobiassolosche...@googlemail.com> wrote:
> >
> > > Hi,
> > >
> > > from what I can see on Wicket bootstrap - there is no integration for
> > that:
> > >
> > > http://wb-mgrigorov.rhcloud.com/components
> > >
> > > But it should be no problem to implement it. :-)
> > >
> > > kind regards
> > >
> > > Tobias
> > >
> > > > Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
> > > reier...@gmail.com>:
> > > >
> > > > Hi Wicketeers,
> > > >
> > > > Does anyone has rolled out a wicket wrapper for
> > > >
> > > > http://www.eyecon.ro/bootstrap-slider/
> > > >
> > > > ?
> > > >
> > > > --
> > > > Regards - Ernesto Reinaldo Barreiro
> > >
> > > -
> > > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > > For additional commands, e-mail: users-h...@wicket.apache.org
> > >
> > >
> >
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
> >
>



-- 
Regards - Ernesto Reinaldo Barreiro


Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Ernesto Reinaldo Barreiro
https://github.com/l0rdn1kk0n/wicket-bootstrap/pull/574

work in progress :-)

On Wed, Dec 30, 2015 at 9:16 AM, Ernesto Reinaldo Barreiro <
reier...@gmail.com> wrote:

> Thanks to you both for helping keep wicket alive and kicking!
>
> On Wed, Dec 30, 2015 at 9:13 AM, Martin Grigorov 
> wrote:
>
>> Thank you, Ernesto!
>> On Dec 30, 2015 10:12 AM, "Ernesto Reinaldo Barreiro" > >
>> wrote:
>>
>> > Thanks for your replay. I will roll out such an implementation and
>> create a
>> > PR against wicket-bootstrap
>> >
>> > On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
>> > tobiassolosche...@googlemail.com> wrote:
>> >
>> > > Hi,
>> > >
>> > > from what I can see on Wicket bootstrap - there is no integration for
>> > that:
>> > >
>> > > http://wb-mgrigorov.rhcloud.com/components
>> > >
>> > > But it should be no problem to implement it. :-)
>> > >
>> > > kind regards
>> > >
>> > > Tobias
>> > >
>> > > > Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
>> > > reier...@gmail.com>:
>> > > >
>> > > > Hi Wicketeers,
>> > > >
>> > > > Does anyone has rolled out a wicket wrapper for
>> > > >
>> > > > http://www.eyecon.ro/bootstrap-slider/
>> > > >
>> > > > ?
>> > > >
>> > > > --
>> > > > Regards - Ernesto Reinaldo Barreiro
>> > >
>> > > -
>> > > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> > > For additional commands, e-mail: users-h...@wicket.apache.org
>> > >
>> > >
>> >
>> >
>> > --
>> > Regards - Ernesto Reinaldo Barreiro
>> >
>>
>
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>



-- 
Regards - Ernesto Reinaldo Barreiro


Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Maxim Solodovnik
Thanks Ernesto
I believe this will be useful component :)

On Wed, Dec 30, 2015 at 5:20 PM, Ernesto Reinaldo Barreiro <
reier...@gmail.com> wrote:

> https://github.com/l0rdn1kk0n/wicket-bootstrap/pull/574
>
> work in progress :-)
>
> On Wed, Dec 30, 2015 at 9:16 AM, Ernesto Reinaldo Barreiro <
> reier...@gmail.com> wrote:
>
> > Thanks to you both for helping keep wicket alive and kicking!
> >
> > On Wed, Dec 30, 2015 at 9:13 AM, Martin Grigorov 
> > wrote:
> >
> >> Thank you, Ernesto!
> >> On Dec 30, 2015 10:12 AM, "Ernesto Reinaldo Barreiro" <
> reier...@gmail.com
> >> >
> >> wrote:
> >>
> >> > Thanks for your replay. I will roll out such an implementation and
> >> create a
> >> > PR against wicket-bootstrap
> >> >
> >> > On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
> >> > tobiassolosche...@googlemail.com> wrote:
> >> >
> >> > > Hi,
> >> > >
> >> > > from what I can see on Wicket bootstrap - there is no integration
> for
> >> > that:
> >> > >
> >> > > http://wb-mgrigorov.rhcloud.com/components
> >> > >
> >> > > But it should be no problem to implement it. :-)
> >> > >
> >> > > kind regards
> >> > >
> >> > > Tobias
> >> > >
> >> > > > Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
> >> > > reier...@gmail.com>:
> >> > > >
> >> > > > Hi Wicketeers,
> >> > > >
> >> > > > Does anyone has rolled out a wicket wrapper for
> >> > > >
> >> > > > http://www.eyecon.ro/bootstrap-slider/
> >> > > >
> >> > > > ?
> >> > > >
> >> > > > --
> >> > > > Regards - Ernesto Reinaldo Barreiro
> >> > >
> >> > >
> -
> >> > > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> >> > > For additional commands, e-mail: users-h...@wicket.apache.org
> >> > >
> >> > >
> >> >
> >> >
> >> > --
> >> > Regards - Ernesto Reinaldo Barreiro
> >> >
> >>
> >
> >
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
> >
>
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>



-- 
WBR
Maxim aka solomax


Wicket jQuery UI - Spinner for time

2015-12-30 Thread Ephraim Rosenfeld
Hello Wicket Team:

I would like to use the Wicket jQuery UI "Spinner" widget, as shown here: 
http://www.7thweb.net/wicket-jquery-ui/spinner/DefaultSpinnerPage?0, for a time 
field, like this example: 
https://jqueryui.com/resources/demos/spinner/time.html. This example adds some 
additional jQuery Widget Factory code to override the default functionality to 
format a date into a time field, e.g. '11:47 AM', and likewise, to parse new 
input back into a date.

Is this possible to do via Wicket? Adding the additional jQuery Widget Factory 
code in the example above did not seem to do the trick.

I was thinking of using Ajax to update the component on the "onspin" event, 
which gets fired when one of the spinner arrow buttons are pressed; however, I 
have no indication as to whether the value should be incremented or 
decremented. Capturing the event on the "onspinstop" event is sort of too late, 
because at this point, the widget already gets populated with the integer value 
as determined by the arrow buttons.

The jQuery UI documentation here 
(http://api.jqueryui.com/spinner/#event-spin)
 states that the input can be obtained on the "onspin" event using the 
"ui.value" property, and this can be used to determine whether the value in the 
field is to be incremented/decremented. Is this property exposed on the Java 
layer via Wicket?

I am using Wicket version 6.15.

Thank you in advance,

- Ephraim


Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Tobias Soloschenko
Great! Looking forward to see the result! :-)

Thank you!

kind regards

Tobias

> Am 30.12.2015 um 12:21 schrieb Maxim Solodovnik :
> 
> Thanks Ernesto
> I believe this will be useful component :)
> 
> On Wed, Dec 30, 2015 at 5:20 PM, Ernesto Reinaldo Barreiro <
> reier...@gmail.com> wrote:
> 
>> https://github.com/l0rdn1kk0n/wicket-bootstrap/pull/574
>> 
>> work in progress :-)
>> 
>> On Wed, Dec 30, 2015 at 9:16 AM, Ernesto Reinaldo Barreiro <
>> reier...@gmail.com> wrote:
>> 
>>> Thanks to you both for helping keep wicket alive and kicking!
>>> 
>>> On Wed, Dec 30, 2015 at 9:13 AM, Martin Grigorov 
>>> wrote:
>>> 
 Thank you, Ernesto!
 On Dec 30, 2015 10:12 AM, "Ernesto Reinaldo Barreiro" <
>> reier...@gmail.com
 wrote:
 
> Thanks for your replay. I will roll out such an implementation and
 create a
> PR against wicket-bootstrap
> 
> On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
> tobiassolosche...@googlemail.com> wrote:
> 
>> Hi,
>> 
>> from what I can see on Wicket bootstrap - there is no integration
>> for
> that:
>> 
>> http://wb-mgrigorov.rhcloud.com/components
>> 
>> But it should be no problem to implement it. :-)
>> 
>> kind regards
>> 
>> Tobias
>> 
 Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
>>> reier...@gmail.com>:
>>> 
>>> Hi Wicketeers,
>>> 
>>> Does anyone has rolled out a wicket wrapper for
>>> 
>>> http://www.eyecon.ro/bootstrap-slider/
>>> 
>>> ?
>>> 
>>> --
>>> Regards - Ernesto Reinaldo Barreiro
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
> 
> 
> --
> Regards - Ernesto Reinaldo Barreiro
>>> 
>>> 
>>> 
>>> --
>>> Regards - Ernesto Reinaldo Barreiro
>> 
>> 
>> 
>> --
>> Regards - Ernesto Reinaldo Barreiro
> 
> 
> 
> -- 
> WBR
> Maxim aka solomax

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



Wicket CSRF/XSRF protection

2015-12-30 Thread andrea

Hi all,

Starting from [this][1] question on stackoverflow, I'm going to ask one 
thing more.


I've developed a web application in which Apache Wicket plays as "REST 
backend", it only exposes HTTP Resources, there is an application and 
there are no pages, and no html related.

All "frontend" is developed in AngularJS.

Now, I need protection against CSRF attacks. AngularJS documentation says:

To take advantage of this [angular XSRF protection], your server needs to set a 
token in a

JavaScript readable session cookie called XSRF-TOKEN on first HTTP GET

request. On subsequent non-GET requests the server can verify that the

cookie matches X-XSRF-TOKEN HTTP header, and therefore be sure that

only JavaScript running on your domain could have read the token.


How can I get this token managed by Apache Wicket?

Are there wicket implementations of such mechanism?

I found /*CsrfPreventionRequestCycleListener*/ but this doesn't protect 
all requests, it seems to be configured (by default) only to protect 
ajax requests on components or links; or /*CryptoMapper*/ with 
/*KeyInSessionSunJceCryptFactory*/, but this does not seem to do what 
I'm looking for.
I "just" want to send a token, not to crypt urls, but if guarantees the 
same protection I'll do.


I've not found so much on documentation, can you help me?


  [1]: 
http://stackoverflow.com/questions/29881338/add-csrf-protection-header-to-wicket-ajax-call#new-answer


Best regards,
Andrea


Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Martin Grigorov
Thank you, Ernesto!
On Dec 30, 2015 10:12 AM, "Ernesto Reinaldo Barreiro" 
wrote:

> Thanks for your replay. I will roll out such an implementation and create a
> PR against wicket-bootstrap
>
> On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
> tobiassolosche...@googlemail.com> wrote:
>
> > Hi,
> >
> > from what I can see on Wicket bootstrap - there is no integration for
> that:
> >
> > http://wb-mgrigorov.rhcloud.com/components
> >
> > But it should be no problem to implement it. :-)
> >
> > kind regards
> >
> > Tobias
> >
> > > Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
> > reier...@gmail.com>:
> > >
> > > Hi Wicketeers,
> > >
> > > Does anyone has rolled out a wicket wrapper for
> > >
> > > http://www.eyecon.ro/bootstrap-slider/
> > >
> > > ?
> > >
> > > --
> > > Regards - Ernesto Reinaldo Barreiro
> >
> > -
> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > For additional commands, e-mail: users-h...@wicket.apache.org
> >
> >
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>


Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Tobias Soloschenko
Hi,

from what I can see on Wicket bootstrap - there is no integration for that:

http://wb-mgrigorov.rhcloud.com/components

But it should be no problem to implement it. :-)

kind regards

Tobias

> Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro :
> 
> Hi Wicketeers,
> 
> Does anyone has rolled out a wicket wrapper for
> 
> http://www.eyecon.ro/bootstrap-slider/
> 
> ?
> 
> -- 
> Regards - Ernesto Reinaldo Barreiro

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



Re: wrapper for http://www.eyecon.ro/bootstrap-slider/

2015-12-30 Thread Ernesto Reinaldo Barreiro
Thanks for your replay. I will roll out such an implementation and create a
PR against wicket-bootstrap

On Wed, Dec 30, 2015 at 9:09 AM, Tobias Soloschenko <
tobiassolosche...@googlemail.com> wrote:

> Hi,
>
> from what I can see on Wicket bootstrap - there is no integration for that:
>
> http://wb-mgrigorov.rhcloud.com/components
>
> But it should be no problem to implement it. :-)
>
> kind regards
>
> Tobias
>
> > Am 30.12.2015 um 08:21 schrieb Ernesto Reinaldo Barreiro <
> reier...@gmail.com>:
> >
> > Hi Wicketeers,
> >
> > Does anyone has rolled out a wicket wrapper for
> >
> > http://www.eyecon.ro/bootstrap-slider/
> >
> > ?
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Regards - Ernesto Reinaldo Barreiro


Re: Wicket CSRF/XSRF protection

2015-12-30 Thread Martin Grigorov
Hi,

You can use CookieUtils to write the cookie.
Later in each request you could use WebRequest.getHeader(String) or
@HeaderParam if this is supported.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Wed, Dec 30, 2015 at 9:31 AM, andrea 
wrote:

> Hi all,
>
> Starting from [this][1] question on stackoverflow, I'm going to ask one
> thing more.
>
> I've developed a web application in which Apache Wicket plays as "REST
> backend", it only exposes HTTP Resources, there is an application and there
> are no pages, and no html related.
> All "frontend" is developed in AngularJS.
>
> Now, I need protection against CSRF attacks. AngularJS documentation says:
>
> To take advantage of this [angular XSRF protection], your server needs to
> set a token in a
>
> JavaScript readable session cookie called XSRF-TOKEN on first HTTP GET
>
> request. On subsequent non-GET requests the server can verify that the
>
> cookie matches X-XSRF-TOKEN HTTP header, and therefore be sure that
>
> only JavaScript running on your domain could have read the token.
>
>
> How can I get this token managed by Apache Wicket?
>
> Are there wicket implementations of such mechanism?
>
> I found /*CsrfPreventionRequestCycleListener*/ but this doesn't protect
> all requests, it seems to be configured (by default) only to protect ajax
> requests on components or links; or /*CryptoMapper*/ with
> /*KeyInSessionSunJceCryptFactory*/, but this does not seem to do what I'm
> looking for.
> I "just" want to send a token, not to crypt urls, but if guarantees the
> same protection I'll do.
>
> I've not found so much on documentation, can you help me?
>
>
>   [1]:
> http://stackoverflow.com/questions/29881338/add-csrf-protection-header-to-wicket-ajax-call#new-answer
>
> Best regards,
> Andrea
>