handleRequest: and Seaside 3

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

handleRequest: and Seaside 3

Martin Polák
Hi there,
        In my Seaside 2.8 application I have overriden #handleRequest: method  
of WAApplication to return WAResponse for some particular URL. For  
example for http://localhost:8080/app/items.xml it returned XML with  
all items. Now in Seaside 3, there is no #handleRequest: in  
WAApplication and I'm not sure, how to achieve the same functionality.  
Any suggestions, please?

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

Re: handleRequest: and Seaside 3

Lukas Renggli
Hi Martin,

Please check the documentation on the changes on

    http://www.seaside.st/community/development/seaside30/WARequestHandler

and let us know if anything is missing.

Lukas

2010/9/15 Martin Polák <[hidden email]>:

> Hi there,
>        In my Seaside 2.8 application I have overriden #handleRequest: method
> of WAApplication to return WAResponse for some particular URL. For example
> for http://localhost:8080/app/items.xml it returned XML with all items. Now
> in Seaside 3, there is no #handleRequest: in WAApplication and I'm not sure,
> how to achieve the same functionality. Any suggestions, please?
>
> Thanks,
> Martin
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>



--
Lukas Renggli
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: handleRequest: and Seaside 3

Martin Polák
Thanks Lukas,
        as usually, it was my stupidity not to check documentation first.  
Documentation is clear and everything is working now well. BTW Seaside  
3.0 is handling requests much better than Seaside 2.8 as I can see.

Martin


On 16.9.2010, at 9:06, Lukas Renggli wrote:

> Hi Martin,
>
> Please check the documentation on the changes on
>
>    http://www.seaside.st/community/development/seaside30/WARequestHandler
>
> and let us know if anything is missing.
>
> Lukas

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

Re: handleRequest: and Seaside 3

mozillanerd
Could you share the full solution? I would appreciate seeing it and stepping
through it to learn.
Thanks



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

Re: handleRequest: and Seaside 3

Martin Polák
Of course, here is the complete method:

        handleFiltered: aRequestContext
        aRequestContext request uri path last = 'tip.csv'
                ifTrue: [
                        aRequestContext
                                respond: [ :response |
                                        response
                                                contentType: WAMimeType textPlain;
                                                nextPutAll: self tipCsv asString ] ].
        super handleFiltered: aRequestContext

I have it as instance method of my custom application class, which  
overrides default WAApplication. self tipCsv generates the CSV file,  
which is returned in response.

Martin


On 25.9.2010, at 2:58, fritz schenk wrote:

> Could you share the full solution? I would appreciate seeing it and  
> stepping
> through it to learn.
> Thanks
>
>
>
> _______________________________________________
> 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