On Jun 19, 4:11 pm, Graham Dumpleton <[email protected]>
wrote:
> On Jun 19, 2:48 pm, 大郎 <[email protected]> wrote:
>
> > On Fri, Jun 19, 2009 at 12:07 PM, alecwh <[email protected]> wrote:
> > > What's the issue here? It looks like web.py, python, and mod_wsgi are
> > > functioning... it's just asking me to download the output, instead of
> > > displaying it in the browser.
>
> > check the .htaccess, and look at 
> > this:http://webpy.org/cookbook/mod_wsgi-apache
>
> That configuration example is wrong. You should not have a trailing
> slash on RHS, ie.,
>
>   WSGIScriptAlias /appname /var/www/webpy-app/code.py/
>
> is wrong. Should be:
>
>   WSGIScriptAlias /appname /var/www/webpy-app/code.py
>
> Setting:
>
>   AddType text/html .py
>
> is also sort of bad practice. The web application itself should be
> implemented properly to set the content type of all responses.

So, get rid of the AddType.

If that doesn't work try having the application call:

  web.header('Content-Type','text/plain')

before returning the string, although for plain text the latter
shouldn't be required as DefaultType for Apache should be 'text/plain'
unless you have fiddled with it.

Graham
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web.py" 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/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to