Your Django code looks fine to me. Did you try debugging it? What does
req.content return?

On Sep 20, 12:51 am, uo <[EMAIL PROTECTED]> wrote:
> Alexander Kojevnikov wrote:
> > fetch() returns a Response object. I guess you are writing it to the
> > output stream which results in all information being shown, including
> > the headers.
>
> > Instead you need to output only the content. If you are using the
> > webapp framework the code will look like this:
>
> >     response = urlfetch.fetch(URL)
> >     self.response.out.write(response.content)
>
> >http://code.google.com/appengine/docs/urlfetch/responseobjects.html
>
> > On Sep 19, 9:03 am, uo <[EMAIL PROTECTED]> wrote:
> > > Hey people thanks for all your help.I have a problem with
> > > urlfetch...im harvesting data from a webpage which i get using
> > > urlfetch,fetch(url) .After im done parsing the pages and i try to
> > > render the info,,, it renders badly as on top i get to see the
> > > headers.. ir content-type status...etc and consequently the page
> > > doesnt render and the html code is shown as is.How can i remove the
> > > headers? Pliz help
>
> What are my options if im using the django framework...where i dont
> deal with the webapp.RequestHandler class directly but rather through
> urls.py through urls which return a  HttpResponse object.I have
> tried    req=urlfetch.fetch(url)
>
> response= HttpResponse()
>
> response.write(req.content)
>
> return response
>
> but it gives me the very same ugly looking page , with unrendered html
> tags and furthermore it replaces the tags i put in the templates
> putting &lt; and &gt; in place of < and >.Anyone pliz help
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to