Skip to content

Commit

Permalink
Add webpy example
Browse files Browse the repository at this point in the history
  • Loading branch information
nkchenz committed Nov 24, 2011
1 parent fa8a1b0 commit 24552a5
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
8 changes: 8 additions & 0 deletions docs/framework.rst
Expand Up @@ -210,3 +210,11 @@ Uliweb中内置了一个对sae支持的app,还在不断完善中,目前可

这样就配置好了。而相关的数据库表的创建维护因为sae不能使用命令行,所以要按sae的
文档说明通过phpMyAdmin来导入。以后Uliweb会増加相应的维护页面来做这事。


web.py
---------

index.wsgi

.. literalinclude:: ../examples/webpy/1/index.wsgi
16 changes: 16 additions & 0 deletions examples/webpy/1/index.wsgi
@@ -0,0 +1,16 @@

import sae
import web

urls = (
'/', 'Hello'
)

class Hello:
def GET(self):
web.header("Content-Type", "text/plain")
return 'Hello, Webpy!'

app = web.application(urls, globals()).wsgifunc()

application = sae.create_wsgi_app(app)

0 comments on commit 24552a5

Please sign in to comment.