On Wednesday, August 22, 2012 7:01:53 AM UTC+12, Barry wrote: > > Hi I'm having some problems setting up webpy on mac OS X. I've got webpy > and mod_wsgi installed correctly but when I go to > http://localhost/test/code.py it just shows the code in the browser > instead of hello, world. > > This is what i've got in my httpd.conf file: > > LoadModule wsgi_module libexec/apache2/mod_wsgi.so > > WSGIScriptAlias /test /Users/Administrator/web/code.py/ > > Alias /test /Users/Administrator/web/ > > AddType text/html .py > > <Directory /Users/Administrator/web/> > Options Indexes FollowSymLinks > Order deny,allow > Allow from all > </Directory> > > and in my code.py file I have: > > import web > > urls = ( > '/.*', 'hello', > ) > > class hello: > def GET(self): > return "Hello, world." > > application = web.application(urls, globals()).wsgifunc() > > Any help would be greatly appreciated. >
Update: I changed this: Alias /test /Users/Administrator/web/ to this: Alias /test/static /Users/Administrator/web/static/ Then I noticed there was an indentation error in the python code do fixed that. All working now. -- You received this message because you are subscribed to the Google Groups "web.py" group. To view this discussion on the web visit https://groups.google.com/d/msg/webpy/-/sEgF_FCBtDkJ. To post to this group, send email to webpy@googlegroups.com. To unsubscribe from this group, send email to webpy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/webpy?hl=en.