Multiple file uploads

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

Multiple file uploads

Louis LaBrunda
Hi,

As part of a new Seaside project I expect to have a page where between five
and ten files will need to be uploaded.  The first thought is to have a
fileUpload and callback for each file and expect that the files will be
uploaded one at a time after a submit button is clicked.

I am wondering if there is a way to have the first fileUpload start and
upload (maybe with some Ajax function) while the next file to be uploaded
is being named.  Any ideas are welcome.

Lou
-----------------------------------------------------------
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon
mailto:[hidden email] http://www.Keystone-Software.com

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

Seaside Async and form submission

Carl Gundel
I'm using Async with my Run BASIC project.  I am still using Seaside  
2.6, but I plan to migrate forward as soon as I can get my Ajax stuff  
working okay.  have a dynamically generated form with a couple of  
listboxes and an anchor.  When the link is clicked I am expecting the  
values to get scraped from the controls and assigned to my model, but  
it doesn't seem to be happening.  The form is getting built and  
rendered correctly as far as I can tell.

The renderContentOn: method for my component looks like this:

renderContentOn: html
        | selectTag |
        selectTag := html select.
        selectTag id: self id.
        self height ifNotNil: [selectTag size: self height].
        selectTag
                list: self list;
                on: #selectedItem of: self

Do I have to do something special?  Is there a known bug in this  
version of Seaside+Async that requires an upgrade for this to work?

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

Re: Seaside Async and form submission

Carl Gundel

On Feb 18, 2009, at 12:59 PM, Carl Gundel wrote:

> I'm using Async with my Run BASIC project.  I am still using Seaside  
> 2.6, but I plan to migrate forward as soon as I can get my Ajax  
> stuff working okay.  have a dynamically generated form with a couple  
> of listboxes and an anchor.  When the link is clicked I am expecting  
> the values to get scraped from the controls and assigned to my  
> model, but it doesn't seem to be happening.  The form is getting  
> built and rendered correctly as far as I can tell.

Okay, here is a complete tiny class that seems to exhibit the same  
behavior.  The counter increments when the anchor is clicked, but the  
value of selection is always nil.

Any ideas?

-Carl

Smalltalk defineClass: #AsyncTest
        superclass: #{Seaside.WAComponent}
        indexedType: #none
        private: false
        instanceVariableNames: 'list selection counter '
        classInstanceVariableNames: ''
        imports: ''
        category: 'Run BASIC'!

!AsyncTest class methodsFor: 'as yet unclassified'!

canBeRoot
        ^ true!

initialize
        self registerAsApplication: 'asyncTest'.! !

!AsyncTest methodsFor: 'rendering'!

renderContentOn: html
        self renderOnHtml: html!

rendererClass
        ^Seaside.WARenderCanvas!

renderOnHtml: html
        | select anchor |
        html
                text: 'Async test';
                break.
        (html form)
                id: 'testForm';
                with:
                                [html
                                        text: 'Counter = ' , self counter asString;
                                        break.
                                (html div)
                                        id: 'section';
                                        with:
                                                        [select := html select.
                                                        select list: self list.
                                                        select on: #selection of: self.
                                                        anchor := html anchor.
                                                        anchor
                                                                liveCallback:
                                                                                [:h |
                                                                                self counter: counter + 1.
                                                                                self renderOnHtml: h];
                                                                submitFormNamed: 'testForm';
                                                                text: 'test'.
                                                        html break.
                                                        html text: self selection]]! !

!AsyncTest methodsFor: 'accessing'!

counter
        counter isNil ifTrue: [ counter := 0 ].
        ^counter!

counter: anObject
        counter := anObject!

list
        list isNil ifTrue: [ list := OrderedCollection with: '1' with: 'one'  
with: 'won' with: 'Juan' ].
        ^list!

list: anObject
        list := anObject!

selection
        ^selection!

selection: anObject
        selection := anObject! !

#{AsyncTest} initialize!

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

Re: Multiple file uploads

Lukas Renggli
In reply to this post by Louis LaBrunda
> I am wondering if there is a way to have the first fileUpload start and
> upload (maybe with some Ajax function) while the next file to be uploaded
> is being named.  Any ideas are welcome.

Check out these threads, they might help you:

http://lists.squeakfoundation.org/pipermail/seaside/2009-January/019599.html
http://lists.squeakfoundation.org/pipermail/seaside/2008-January/016079.html
http://lists.squeakfoundation.org/pipermail/seaside/2008-January/016137.html

Lukas

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

Re: Seaside Async and form submission

Carl Gundel
In reply to this post by Carl Gundel
I tried this with Seaside 2.8 with the same results.  :-/  I also  
noticed that my renderOnHtml: method was rendering the form again, so  
I put the form code in the renderContentOn: method.  No difference.

Okay, I can see that this can be made to work (sort of) by assigning  
the liveCallback to the selectTag, but this just doesn't meet my  
needs.  Isn't there some way to force a form's contents to be  
submitted when an anchor has a liveCallback?  Shouldn't an Ajax action  
be able to use all the contents of a form?

-Carl

On Feb 18, 2009, at 2:42 PM, Carl Gundel wrote:

>
> On Feb 18, 2009, at 12:59 PM, Carl Gundel wrote:
>
>> I'm using Async with my Run BASIC project.  I am still using  
>> Seaside 2.6, but I plan to migrate forward as soon as I can get my  
>> Ajax stuff working okay.  have a dynamically generated form with a  
>> couple of listboxes and an anchor.  When the link is clicked I am  
>> expecting the values to get scraped from the controls and assigned  
>> to my model, but it doesn't seem to be happening.  The form is  
>> getting built and rendered correctly as far as I can tell.
>
> Okay, here is a complete tiny class that seems to exhibit the same  
> behavior.  The counter increments when the anchor is clicked, but  
> the value of selection is always nil.
>
> Any ideas?
>
> -Carl
>
> Smalltalk defineClass: #AsyncTest
> superclass: #{Seaside.WAComponent}
> indexedType: #none
> private: false
> instanceVariableNames: 'list selection counter '
> classInstanceVariableNames: ''
> imports: ''
> category: 'Run BASIC'!
>
> !AsyncTest class methodsFor: 'as yet unclassified'!
>
> canBeRoot
> ^ true!
>
> initialize
> self registerAsApplication: 'asyncTest'.! !
>
> !AsyncTest methodsFor: 'rendering'!
>
> renderContentOn: html
> self renderOnHtml: html!
>
> rendererClass
> ^Seaside.WARenderCanvas!
>
> renderOnHtml: html
> | select anchor |
> html
> text: 'Async test';
> break.
> (html form)
> id: 'testForm';
> with:
> [html
> text: 'Counter = ' , self counter asString;
> break.
> (html div)
> id: 'section';
> with:
> [select := html select.
> select list: self list.
> select on: #selection of: self.
> anchor := html anchor.
> anchor
> liveCallback:
> [:h |
> self counter: counter + 1.
> self renderOnHtml: h];
> submitFormNamed: 'testForm';
> text: 'test'.
> html break.
> html text: self selection]]! !
>
> !AsyncTest methodsFor: 'accessing'!
>
> counter
> counter isNil ifTrue: [ counter := 0 ].
> ^counter!
>
> counter: anObject
> counter := anObject!
>
> list
> list isNil ifTrue: [ list := OrderedCollection with: '1' with:  
> 'one' with: 'won' with: 'Juan' ].
> ^list!
>
> list: anObject
> list := anObject!
>
> selection
> ^selection!
>
> selection: anObject
> selection := anObject! !
>
> #{AsyncTest} initialize!
>

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

Re: Re: Seaside Async and form submission

Ryan Simmons-2
Hi Carl you can do this with Scriptaculous as follows
just change the anchor to

anchor
  onClick: (html updater
                     triggerForm: 'testForm';
                     id: '' " You need a id fro the html element Id
that you are updating with the render "
                     callback: [:r |
                              self counter: counter + 1.
                              self renderOnHtml: r]);
  with: 'test'.

This is from 2.8 though, never worked on 2.6 :)

Ryan

2009/2/18 Carl Gundel <[hidden email]>:

> I tried this with Seaside 2.8 with the same results.  :-/  I also noticed
> that my renderOnHtml: method was rendering the form again, so I put the form
> code in the renderContentOn: method.  No difference.
>
> Okay, I can see that this can be made to work (sort of) by assigning the
> liveCallback to the selectTag, but this just doesn't meet my needs.  Isn't
> there some way to force a form's contents to be submitted when an anchor has
> a liveCallback?  Shouldn't an Ajax action be able to use all the contents of
> a form?
>
> -Carl
>
> On Feb 18, 2009, at 2:42 PM, Carl Gundel wrote:
>
>>
>> On Feb 18, 2009, at 12:59 PM, Carl Gundel wrote:
>>
>>> I'm using Async with my Run BASIC project.  I am still using Seaside 2.6,
>>> but I plan to migrate forward as soon as I can get my Ajax stuff working
>>> okay.  have a dynamically generated form with a couple of listboxes and an
>>> anchor.  When the link is clicked I am expecting the values to get scraped
>>> from the controls and assigned to my model, but it doesn't seem to be
>>> happening.  The form is getting built and rendered correctly as far as I can
>>> tell.
>>
>> Okay, here is a complete tiny class that seems to exhibit the same
>> behavior.  The counter increments when the anchor is clicked, but the value
>> of selection is always nil.
>>
>> Any ideas?
>>
>> -Carl
>>
>> Smalltalk defineClass: #AsyncTest
>>        superclass: #{Seaside.WAComponent}
>>        indexedType: #none
>>        private: false
>>        instanceVariableNames: 'list selection counter '
>>        classInstanceVariableNames: ''
>>        imports: ''
>>        category: 'Run BASIC'!
>>
>> !AsyncTest class methodsFor: 'as yet unclassified'!
>>
>> canBeRoot
>>        ^ true!
>>
>> initialize
>>        self registerAsApplication: 'asyncTest'.! !
>>
>> !AsyncTest methodsFor: 'rendering'!
>>
>> renderContentOn: html
>>        self renderOnHtml: html!
>>
>> rendererClass
>>        ^Seaside.WARenderCanvas!
>>
>> renderOnHtml: html
>>        | select anchor |
>>        html
>>                text: 'Async test';
>>                break.
>>        (html form)
>>                id: 'testForm';
>>                with:
>>                                [html
>>                                        text: 'Counter = ' , self counter
>> asString;
>>                                        break.
>>                                (html div)
>>                                        id: 'section';
>>                                        with:
>>                                                        [select := html
>> select.
>>                                                        select list: self
>> list.
>>                                                        select on:
>> #selection of: self.
>>                                                        anchor := html
>> anchor.
>>                                                        anchor
>>
>>  liveCallback:
>>
>>      [:h |
>>
>>      self counter: counter + 1.
>>
>>      self renderOnHtml: h];
>>
>>  submitFormNamed: 'testForm';
>>                                                                text:
>> 'test'.
>>                                                        html break.
>>                                                        html text: self
>> selection]]! !
>>
>> !AsyncTest methodsFor: 'accessing'!
>>
>> counter
>>        counter isNil ifTrue: [ counter := 0 ].
>>        ^counter!
>>
>> counter: anObject
>>        counter := anObject!
>>
>> list
>>        list isNil ifTrue: [ list := OrderedCollection with: '1' with:
>> 'one' with: 'won' with: 'Juan' ].
>>        ^list!
>>
>> list: anObject
>>        list := anObject!
>>
>> selection
>>        ^selection!
>>
>> selection: anObject
>>        selection := anObject! !
>>
>> #{AsyncTest} initialize!
>>
>
> _______________________________________________
> 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: Re: Seaside Async and form submission

Ryan Simmons-2
Had a quick look at Seaside Async, can't see that it supports
submitting a whole form.

If you need to use Seaside Async, you could use liveCallbacks on all
the selects but link them up to a momento then commit the momento back
to your model when the user clicks on the anchor

2009/2/19 Ryan Simmons <[hidden email]>:

> Hi Carl you can do this with Scriptaculous as follows
> just change the anchor to
>
> anchor
>  onClick: (html updater
>                     triggerForm: 'testForm';
>                     id: '' " You need a id fro the html element Id
> that you are updating with the render "
>                     callback: [:r |
>                              self counter: counter + 1.
>                              self renderOnHtml: r]);
>  with: 'test'.
>
> This is from 2.8 though, never worked on 2.6 :)
>
> Ryan
>
> 2009/2/18 Carl Gundel <[hidden email]>:
>> I tried this with Seaside 2.8 with the same results.  :-/  I also noticed
>> that my renderOnHtml: method was rendering the form again, so I put the form
>> code in the renderContentOn: method.  No difference.
>>
>> Okay, I can see that this can be made to work (sort of) by assigning the
>> liveCallback to the selectTag, but this just doesn't meet my needs.  Isn't
>> there some way to force a form's contents to be submitted when an anchor has
>> a liveCallback?  Shouldn't an Ajax action be able to use all the contents of
>> a form?
>>
>> -Carl
>>
>> On Feb 18, 2009, at 2:42 PM, Carl Gundel wrote:
>>
>>>
>>> On Feb 18, 2009, at 12:59 PM, Carl Gundel wrote:
>>>
>>>> I'm using Async with my Run BASIC project.  I am still using Seaside 2.6,
>>>> but I plan to migrate forward as soon as I can get my Ajax stuff working
>>>> okay.  have a dynamically generated form with a couple of listboxes and an
>>>> anchor.  When the link is clicked I am expecting the values to get scraped
>>>> from the controls and assigned to my model, but it doesn't seem to be
>>>> happening.  The form is getting built and rendered correctly as far as I can
>>>> tell.
>>>
>>> Okay, here is a complete tiny class that seems to exhibit the same
>>> behavior.  The counter increments when the anchor is clicked, but the value
>>> of selection is always nil.
>>>
>>> Any ideas?
>>>
>>> -Carl
>>>
>>> Smalltalk defineClass: #AsyncTest
>>>        superclass: #{Seaside.WAComponent}
>>>        indexedType: #none
>>>        private: false
>>>        instanceVariableNames: 'list selection counter '
>>>        classInstanceVariableNames: ''
>>>        imports: ''
>>>        category: 'Run BASIC'!
>>>
>>> !AsyncTest class methodsFor: 'as yet unclassified'!
>>>
>>> canBeRoot
>>>        ^ true!
>>>
>>> initialize
>>>        self registerAsApplication: 'asyncTest'.! !
>>>
>>> !AsyncTest methodsFor: 'rendering'!
>>>
>>> renderContentOn: html
>>>        self renderOnHtml: html!
>>>
>>> rendererClass
>>>        ^Seaside.WARenderCanvas!
>>>
>>> renderOnHtml: html
>>>        | select anchor |
>>>        html
>>>                text: 'Async test';
>>>                break.
>>>        (html form)
>>>                id: 'testForm';
>>>                with:
>>>                                [html
>>>                                        text: 'Counter = ' , self counter
>>> asString;
>>>                                        break.
>>>                                (html div)
>>>                                        id: 'section';
>>>                                        with:
>>>                                                        [select := html
>>> select.
>>>                                                        select list: self
>>> list.
>>>                                                        select on:
>>> #selection of: self.
>>>                                                        anchor := html
>>> anchor.
>>>                                                        anchor
>>>
>>>  liveCallback:
>>>
>>>      [:h |
>>>
>>>      self counter: counter + 1.
>>>
>>>      self renderOnHtml: h];
>>>
>>>  submitFormNamed: 'testForm';
>>>                                                                text:
>>> 'test'.
>>>                                                        html break.
>>>                                                        html text: self
>>> selection]]! !
>>>
>>> !AsyncTest methodsFor: 'accessing'!
>>>
>>> counter
>>>        counter isNil ifTrue: [ counter := 0 ].
>>>        ^counter!
>>>
>>> counter: anObject
>>>        counter := anObject!
>>>
>>> list
>>>        list isNil ifTrue: [ list := OrderedCollection with: '1' with:
>>> 'one' with: 'won' with: 'Juan' ].
>>>        ^list!
>>>
>>> list: anObject
>>>        list := anObject!
>>>
>>> selection
>>>        ^selection!
>>>
>>> selection: anObject
>>>        selection := anObject! !
>>>
>>> #{AsyncTest} initialize!
>>>
>>
>> _______________________________________________
>> 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: Re: Seaside Async and form submission

Bany, Michel
In reply to this post by Carl Gundel
Hi Carl,

I had a look and found a couple of things I would correct in your tiny class.
Note that I was using VW 7.5 together with Seaside 2.6b1.136 and SeasideAsync 1.61
as found on the VW 7.5 distribution.
1. AsyncTest should be a subclass of WAAsyncComponent
2. Method #rendererClass should be removed to inherit from the superclass

Then I found out that #liveCallback: and #submitFormNamed: 'testForm' are conflicting
since both contribute a 'return false' to the onclick event handler.

So I created a fix for you. See ftp://ftp.bany.fr/seaside/ForCarlGundel.zip

This archive includes your tiny class, a fix to WAHtmlAttributes that makes sure
there is only one 'return false' at the very end, and s-unit tests for the fix.

With the fix, your tiny class works fine in FF, but not in Safari. I didn't try in IE.
I'm not sure you tiny class reflects what you are trying to achieve. This tiny class
does something weird, it submits a form and ajax-updates the whole form in the same
javascript handler. I guess you real app is only ajax-updating portions of the form.

Hope this helps,
Michel.
 
 

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]] On Behalf
> Of Carl Gundel
> Sent: mercredi, 18. février 2009 20:43
> To: Carl Gundel
> Cc: Seaside - general discussion
> Subject: [Seaside] Re: Seaside Async and form submission
>
>
> On Feb 18, 2009, at 12:59 PM, Carl Gundel wrote:
>
> > I'm using Async with my Run BASIC project.  I am still
> using Seaside
> > 2.6, but I plan to migrate forward as soon as I can get my
> Ajax stuff
> > working okay.  have a dynamically generated form with a couple of
> > listboxes and an anchor.  When the link is clicked I am
> expecting the
> > values to get scraped from the controls and assigned to my
> model, but
> > it doesn't seem to be happening.  The form is getting built and
> > rendered correctly as far as I can tell.
>
> Okay, here is a complete tiny class that seems to exhibit the
> same behavior.  The counter increments when the anchor is
> clicked, but the value of selection is always nil.
>
> Any ideas?
>
> -Carl
>
> Smalltalk defineClass: #AsyncTest
> superclass: #{Seaside.WAComponent}
> indexedType: #none
> private: false
> instanceVariableNames: 'list selection counter '
> classInstanceVariableNames: ''
> imports: ''
> category: 'Run BASIC'!
>
> !AsyncTest class methodsFor: 'as yet unclassified'!
>
> canBeRoot
> ^ true!
>
> initialize
> self registerAsApplication: 'asyncTest'.! !
>
> !AsyncTest methodsFor: 'rendering'!
>
> renderContentOn: html
> self renderOnHtml: html!
>
> rendererClass
> ^Seaside.WARenderCanvas!
>
> renderOnHtml: html
> | select anchor |
> html
> text: 'Async test';
> break.
> (html form)
> id: 'testForm';
> with:
> [html
> text: 'Counter = ' ,
> self counter asString;
> break.
> (html div)
> id: 'section';
> with:
> [select
> := html select.
> select
> list: self list.
> select
> on: #selection of: self.
> anchor
> := html anchor.
> anchor
>
> liveCallback:
>
> [:h |
>
> self counter: counter + 1.
>
> self renderOnHtml: h];
>
> submitFormNamed: 'testForm';
>
> text: 'test'.
> html break.
> html
> text: self selection]]! !
>
> !AsyncTest methodsFor: 'accessing'!
>
> counter
> counter isNil ifTrue: [ counter := 0 ].
> ^counter!
>
> counter: anObject
> counter := anObject!
>
> list
> list isNil ifTrue: [ list := OrderedCollection with:
> '1' with: 'one'  
> with: 'won' with: 'Juan' ].
> ^list!
>
> list: anObject
> list := anObject!
>
> selection
> ^selection!
>
> selection: anObject
> selection := anObject! !
>
> #{AsyncTest} initialize!
>
> _______________________________________________
> 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: Re: Seaside Async and form submission

Carl Gundel

On Feb 19, 2009, at 9:42 AM, Bany, Michel wrote:

> Hi Carl,
>
> I had a look and found a couple of things I would correct in your  
> tiny class.
> Note that I was using VW 7.5 together with Seaside 2.6b1.136 and  
> SeasideAsync 1.61
> as found on the VW 7.5 distribution.
> 1. AsyncTest should be a subclass of WAAsyncComponent

The old version of Seaside and Async I am using does not have  
WAAsyncComponent.

>
> 2. Method #rendererClass should be removed to inherit from the  
> superclass

Again, this isn't the case with the version I'm using.

I did make the same changes you mention when I ported the class to  
Seaside 7.6.

> Then I found out that #liveCallback: and #submitFormNamed:  
> 'testForm' are conflicting
> since both contribute a 'return false' to the onclick event handler.
>
> So I created a fix for you. See ftp://ftp.bany.fr/seaside/ForCarlGundel.zip

Cool.  Thanks.


> This archive includes your tiny class, a fix to WAHtmlAttributes  
> that makes sure
> there is only one 'return false' at the very end, and s-unit tests  
> for the fix.

This is fix for Seaside?

> With the fix, your tiny class works fine in FF, but not in Safari. I  
> didn't try in IE.

Ah, well it would need to work for all three.  Maybe there is still a  
way.

> I'm not sure you tiny class reflects what you are trying to achieve.  
> This tiny class
> does something weird, it submits a form and ajax-updates the whole  
> form in the same
> javascript handler. I guess you real app is only ajax-updating  
> portions of the form.

The class doesn't do exactly what I want because of the form.  I also  
noticed it was replacing the form and changed it so that it would  
not.  I mentioned this in a followup post.

However this raises the question of whether there is anything  
technically wrong with a live component replacing the part of the DOM  
tree it lives in, or even the whole page.  Is this going to cause  
weird problems?  This is important to me because Run BASIC is a  
completely open ended programming system.  It helps me if Seaside and  
Async are robust enough to handle this, but I can add Ajax training  
wheels if needed.

Also, it has taken me some time to really understand the idiom of  
Async.  It was easy for me to make wrong assumptions about its  
intended usage.  I have been unable to find any real Async  
documentation since most of the attention goes to Scriptaculous.  I  
have been trying to avoid that since it relies on Prototype which I've  
heard is incompatible with toolkits like Dojo and jQuery.

> Hope this helps,

Thanks.  I'll have a look at the fix.


-Carl Gundel
http://www.runbasic.com


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

Re: Re: Seaside Async and form submission

Carl Gundel

On Feb 19, 2009, at 10:41 AM, Carl Gundel wrote:
>
>>
>> 2. Method #rendererClass should be removed to inherit from the  
>> superclass
>
> Again, this isn't the case with the version I'm using.
>
> I did make the same changes you mention when I ported the class to  
> Seaside 7.6.

Oops, I meant Seaside 2.8 (on VW 7.6).

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

RE: Re: Seaside Async and form submission

Bany, Michel
In reply to this post by Carl Gundel
> The old version of Seaside and Async I am using does not have
> WAAsyncComponent.

OK, but I think my fix may work because class WAHtmlAttribute has been
pretty stable if I recall correctly.


> This is fix for Seaside?

Yes, the fix is for a Seaside class.

> > With the fix, your tiny class works fine in FF, but not in
> Safari. I  
> > didn't try in IE.
>
> Ah, well it would need to work for all three.  Maybe there is
> still a  
> way.


I tried to figure out why it didn't work for Safari and I succeeded in
crashing Safari many times when I added breakpoints in the javascript.


> The class doesn't do exactly what I want because of the form.
>  I also  
> noticed it was replacing the form and changed it so that it would  
> not.  I mentioned this in a followup post.
>
> However this raises the question of whether there is anything  
> technically wrong with a live component replacing the part of
> the DOM  
> tree it lives in, or even the whole page.  Is this going to cause  
> weird problems?  This is important to me because Run BASIC is a  
> completely open ended programming system.  It helps me if
> Seaside and  
> Async are robust enough to handle this, but I can add Ajax training  
> wheels if needed.

Beside suggesting you go for Scriptaculous, I cannot help here, sorry.
(I tried a Scriptaculous version of your tiny class and it worked fine
in Safari).

>
> Also, it has taken me some time to really understand the idiom  
> of Async.  It was easy for me to make wrong assumptions about  
> its intended usage.  I have been unable to find any real Async  
> documentation since most of the attention goes to Scriptaculous.  
> I have been trying to avoid that since it relies on Prototype
> which I've  
> heard is incompatible with toolkits like Dojo and jQuery.

Here is some sort of description of the idiom by Async's author
http://www.cincomsmalltalk.com/userblogs/avi/blogView?entry=3268075684

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

Re: Re: Seaside Async and form submission

Carl Gundel
Thanks so much for all your help!  :-)

-Carl

On Feb 19, 2009, at 1:23 PM, Bany, Michel wrote:

>> The old version of Seaside and Async I am using does not have
>> WAAsyncComponent.
>
> OK, but I think my fix may work because class WAHtmlAttribute has been
> pretty stable if I recall correctly.
>
>
>> This is fix for Seaside?
>
> Yes, the fix is for a Seaside class.
>
>>> With the fix, your tiny class works fine in FF, but not in
>> Safari. I
>>> didn't try in IE.
>>
>> Ah, well it would need to work for all three.  Maybe there is
>> still a
>> way.
>
>
> I tried to figure out why it didn't work for Safari and I succeeded in
> crashing Safari many times when I added breakpoints in the javascript.
>
>
>> The class doesn't do exactly what I want because of the form.
>> I also
>> noticed it was replacing the form and changed it so that it would
>> not.  I mentioned this in a followup post.
>>
>> However this raises the question of whether there is anything
>> technically wrong with a live component replacing the part of
>> the DOM
>> tree it lives in, or even the whole page.  Is this going to cause
>> weird problems?  This is important to me because Run BASIC is a
>> completely open ended programming system.  It helps me if
>> Seaside and
>> Async are robust enough to handle this, but I can add Ajax training
>> wheels if needed.
>
> Beside suggesting you go for Scriptaculous, I cannot help here, sorry.
> (I tried a Scriptaculous version of your tiny class and it worked fine
> in Safari).
>
>>
>> Also, it has taken me some time to really understand the idiom
>> of Async.  It was easy for me to make wrong assumptions about
>> its intended usage.  I have been unable to find any real Async
>> documentation since most of the attention goes to Scriptaculous.
>> I have been trying to avoid that since it relies on Prototype
>> which I've
>> heard is incompatible with toolkits like Dojo and jQuery.
>
> Here is some sort of description of the idiom by Async's author
> http://www.cincomsmalltalk.com/userblogs/avi/blogView?entry=3268075684
>
> _______________________________________________
> 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