存档
-
Test Ajax With JQuery in Google App Engine
使用JQuery测试AJAX在Google App Engine中的用法。 如下图所示,在左边文本框输入一些文字,keyup时右边的文本框也显示相应的文字(以{}包裹)。 [code title="app.yaml"] application: ajaxecho version: 1 runtime: python api_version: 1 handlers: - url: /.* script: echo.py [/code] [code lang="python" title="echo.py"] import os from django.utils import simplejson from google.appengine.ext import webapp from google.appengine.ext.webapp import template from google.appengine.ext.webapp import util # ... class EchoHandler(webapp.RequestHandler): def get(self): template_values = {} path = os.path.join(os.path.dirname(__file__), "echo.html") [...]
2011年11月15日 | 归档于 Web