Datepicker question

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Datepicker question

Sabine Manaa
Hi,

I use datepicker like this:

 html textInput
        value: Date today;
        callback: [ :value |
                        self date: value  ] ;
        script: (( html jQuery new datepicker) onSelect: html jQuery ajax serializeThis).

In case of selecting the date within the datepicker popup (click at a date), it works fine ("self date:" is sent).
But if I change the date within the textInput field, without using the datepicker popup, the callback is not fired.

How can I set the date: also in case that the user types in the date in the text field?

Sabine
Reply | Threaded
Open this post in threaded view
|

Re: Datepicker question

jtuchel
Hi Sabine,

Don you mean you want the #date: method to be called immediately instead of when the form is being submitted? I guess you'd have to attach an onBlur: or better onInput: JavaScript handler to the text input.

Joachim

Sabine Knöfel <[hidden email]> schrieb:

>Hi,
>
>I use datepicker like this:
>
> html textInput
>        value: Date today;
>        callback: [ :value |
>                        self date: value  ] ;
>        script: (( html jQuery new datepicker) onSelect: html jQuery ajax
>serializeThis).
>
>In case of selecting the date within the datepicker popup (click at a date),
>it works fine ("self date:" is sent).
>But if I change the date within the textInput field, without using the
>datepicker popup, the callback is not fired.
>
>How can I set the date: also in case that the user types in the date in the
>text field?
>
>Sabine
>
>
>
>--
>View this message in context: http://forum.world.st/Datepicker-question-tp4672655.html
>Sent from the Seaside General mailing list archive at Nabble.com.
>_______________________________________________
>seaside mailing list
>[hidden email]
>http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Datepicker question

Sabine Manaa
Hi Joachim,

thank you. Yes, I need it I immediately.

I need some help here.
I can alert the value of the text field with some js (see below).
But I dont know how to get the value for setting it into my date attribute.

Any help appreciated.

Sabine

html textInput
        id: 'input';
        value: Date today;
        callback: [ :value |  self date: value ];
        onBlur:
                (html prototype evaluator
                        callback: [ :script |
                            script
                                add:
                                    (JSStream new
                                        nextPutAll: 'alert(document.getElementById(''input'').value) ';
                                        argument: 'xx';
                                        yourself).
                           ]);
        script: (html jQuery new datepicker onSelect: html jQuery ajax serializeThis)



On Thu, Feb 28, 2013 at 12:20 PM, Joachim Tuchel <[hidden email]> wrote:
Hi Sabine,

Don you mean you want the #date: method to be called immediately instead of when the form is being submitted? I guess you'd have to attach an onBlur: or better onInput: JavaScript handler to the text input.

Joachim

Sabine Knöfel <[hidden email]> schrieb:

>Hi,
>
>I use datepicker like this:
>
> html textInput
>        value: Date today;
>        callback: [ :value |
>                        self date: value  ] ;
>        script: (( html jQuery new datepicker) onSelect: html jQuery ajax
>serializeThis).
>
>In case of selecting the date within the datepicker popup (click at a date),
>it works fine ("self date:" is sent).
>But if I change the date within the textInput field, without using the
>datepicker popup, the callback is not fired.
>
>How can I set the date: also in case that the user types in the date in the
>text field?
>
>Sabine
>
>
>
>--
>View this message in context: http://forum.world.st/Datepicker-question-tp4672655.html
>Sent from the Seaside General mailing list archive at Nabble.com.
>_______________________________________________
>seaside mailing list
>[hidden email]
>http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Datepicker question

Ryan Simmons-2
html textInput
        id: 'input';
        value: Date today;
        callback: [ :value |  self date: value ];
        onBlur: (html jQuery ajax serializeThis);
        script: (html jQuery new datepicker onSelect: html jQuery ajax serializeThis)

should work


On 28 February 2013 14:43, Sabine Knöfel <[hidden email]> wrote:
Hi Joachim,

thank you. Yes, I need it I immediately.

I need some help here.
I can alert the value of the text field with some js (see below).
But I dont know how to get the value for setting it into my date attribute.

Any help appreciated.

Sabine

html textInput
        id: 'input';

        value: Date today;
        callback: [ :value |  self date: value ];
        onBlur:
                (html prototype evaluator
                        callback: [ :script |
                            script
                                add:
                                    (JSStream new
                                        nextPutAll: 'alert(document.getElementById(''input'').value) ';
                                        argument: 'xx';
                                        yourself).
                           ]);
        script: (html jQuery new datepicker onSelect: html jQuery ajax serializeThis)




On Thu, Feb 28, 2013 at 12:20 PM, Joachim Tuchel <[hidden email]> wrote:
Hi Sabine,

Don you mean you want the #date: method to be called immediately instead of when the form is being submitted? I guess you'd have to attach an onBlur: or better onInput: JavaScript handler to the text input.

Joachim

Sabine Knöfel <[hidden email]> schrieb:

>Hi,
>
>I use datepicker like this:
>
> html textInput
>        value: Date today;
>        callback: [ :value |
>                        self date: value  ] ;
>        script: (( html jQuery new datepicker) onSelect: html jQuery ajax
>serializeThis).
>
>In case of selecting the date within the datepicker popup (click at a date),
>it works fine ("self date:" is sent).
>But if I change the date within the textInput field, without using the
>datepicker popup, the callback is not fired.
>
>How can I set the date: also in case that the user types in the date in the
>text field?
>
>Sabine
>
>
>
>--
>View this message in context: http://forum.world.st/Datepicker-question-tp4672655.html
>Sent from the Seaside General mailing list archive at Nabble.com.
>_______________________________________________
>seaside mailing list
>[hidden email]
>http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Datepicker question

Sabine Manaa
Ha!
Thank you, Ryan, It works!

On Thu, Feb 28, 2013 at 2:34 PM, Ryan Simmons <[hidden email]> wrote:
html textInput
        id: 'input';
        value: Date today;
        callback: [ :value |  self date: value ];
        onBlur: (html jQuery ajax serializeThis);

        script: (html jQuery new datepicker onSelect: html jQuery ajax serializeThis)

should work


On 28 February 2013 14:43, Sabine Knöfel <[hidden email]> wrote:
Hi Joachim,

thank you. Yes, I need it I immediately.

I need some help here.
I can alert the value of the text field with some js (see below).
But I dont know how to get the value for setting it into my date attribute.

Any help appreciated.

Sabine

html textInput
        id: 'input';

        value: Date today;
        callback: [ :value |  self date: value ];
        onBlur:
                (html prototype evaluator
                        callback: [ :script |
                            script
                                add:
                                    (JSStream new
                                        nextPutAll: 'alert(document.getElementById(''input'').value) ';
                                        argument: 'xx';
                                        yourself).
                           ]);
        script: (html jQuery new datepicker onSelect: html jQuery ajax serializeThis)




On Thu, Feb 28, 2013 at 12:20 PM, Joachim Tuchel <[hidden email]> wrote:
Hi Sabine,

Don you mean you want the #date: method to be called immediately instead of when the form is being submitted? I guess you'd have to attach an onBlur: or better onInput: JavaScript handler to the text input.

Joachim

Sabine Knöfel <[hidden email]> schrieb:

>Hi,
>
>I use datepicker like this:
>
> html textInput
>        value: Date today;
>        callback: [ :value |
>                        self date: value  ] ;
>        script: (( html jQuery new datepicker) onSelect: html jQuery ajax
>serializeThis).
>
>In case of selecting the date within the datepicker popup (click at a date),
>it works fine ("self date:" is sent).
>But if I change the date within the textInput field, without using the
>datepicker popup, the callback is not fired.
>
>How can I set the date: also in case that the user types in the date in the
>text field?
>
>Sabine
>
>
>
>--
>View this message in context: http://forum.world.st/Datepicker-question-tp4672655.html
>Sent from the Seaside General mailing list archive at Nabble.com.
>_______________________________________________
>seaside mailing list
>[hidden email]
>http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside