Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread maverick
Thanks ! As a python/django beginner, I am trying to have something nice from the Java world. I am implement something like Sitemesh(http:// www.opensymphony.com/sitemesh/). The idea is, I can put some tag in the template to quickly include some external URL's output to the current page (with

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread Carl Meyer
On Sep 30, 8:00 pm, maverick <[EMAIL PROTECTED]> wrote: > Hi, I have a django web application, I want to invoke a request of one > URL inside this application, e.g.  "/getdata/", and capture the output > of such URL and do some further processing. > > Of course I can do that by make a real

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread bruno desthuilliers
On 1 oct, 09:52, maverick <[EMAIL PROTECTED]> wrote: > @keith, your suggestion seemed to be make a "real" request? I don't > want to make real request since it's not light weight enough. > > @ Jeff, thanks. I don't want to call from view, I want work with the > "URL". But your suggestion is

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread bruno desthuilliers
On 1 oct, 13:25, Erik Allik <[EMAIL PROTECTED]> wrote: > Don't forget to modify the request object that you pass to the view > accordingly if the view actually uses it or passes it to a function > that does. Otherwise you may run into weird bugs. Hem... yes, indeed. Thanks for the correction.

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread maverick
Thanks a mil! On Oct 1, 12:25 pm, Erik Allik <[EMAIL PROTECTED]> wrote: > Don't forget to modify the request object that you pass to the view   > accordingly if the view actually uses it or passes it to a function   > that does. Otherwise you may run into weird bugs. > > Erik > > On 01.10.2008,

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread Erik Allik
Don't forget to modify the request object that you pass to the view accordingly if the view actually uses it or passes it to a function that does. Otherwise you may run into weird bugs. Erik On 01.10.2008, at 14:13, bruno desthuilliers wrote: > > On 1 oct, 09:52, maverick <[EMAIL

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-10-01 Thread maverick
@keith, your suggestion seemed to be make a "real" request? I don't want to make real request since it's not light weight enough. @ Jeff, thanks. I don't want to call from view, I want work with the "URL". But your suggestion is good, I will look inside django code to see how to do so. On

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-09-30 Thread Jeff Anderson
maverick wrote: > Hi, I have a django web application, I want to invoke a request of one > URL inside this application, e.g. "/getdata/", and capture the output > of such URL and do some further processing. > > Of course I can do that by make a real request, however I feel this > may not be the

Re: How to invoke a request to an URL inside a web app without making a real request?

2008-09-30 Thread Keith Eberle
sure can! take a look @ http://docs.python.org/lib/module-urllib.html keith On Tue, Sep 30, 2008 at 8:00 PM, maverick <[EMAIL PROTECTED]> wrote: > > Hi, I have a django web application, I want to invoke a request of one > URL inside this application, e.g. "/getdata/", and capture the output

How to invoke a request to an URL inside a web app without making a real request?

2008-09-30 Thread maverick
Hi, I have a django web application, I want to invoke a request of one URL inside this application, e.g. "/getdata/", and capture the output of such URL and do some further processing. Of course I can do that by make a real request, however I feel this may not be the best solution, is there any