Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <pre><code>from google.appengine.ext import db from google.appengine.ext import webapp from google.appengine.ext.webapp import template # A class which creates all the pokemon on the server class Pokemondata(db.Model): number = db.IntegerProperty() pokemonname = db.StringProperty() description = db.StringProperty() def post(self): self.session = Session() pnumber = self.request.get('number') pname = self.request.get('pokemonname') pdescription = self.request.get('description') newpoke = Pokemondata(number=pnumber,pokemonname=pname,description=pdescription) newpoke.put() self.session['pokemon'] = pname doRender(self,"board.htm",{}) Page = """ &lt;html manifest="my.manifest"&gt; &lt;head&gt; &lt;!-- All the js and css header links go here --&gt; &lt;/head&gt; &lt;body&gt; &lt;!-- all the needed HTML markup --&gt; &lt;!-- if there is a place you would need to embed values (e.g. a user name), just use %s in its place, e.g. --&gt; &lt;h1&gt;%s's App Engine App&lt;/h&gt; &lt;!-- you can now do a string substitution for the each %s (in order) - see end… &lt;/body&gt; &lt;/html&gt; """ # A class to get / put pokemon in to the server ? class ApplyHandler(webapp.RequestHandler): def post(self): self.session = Session() pnumber = self.request.get('number') pname = self.request.get('pokemonname') pdescription = self.request.get('description') newpoke = Pokemondata(number=pnumber,pokemonname=pname,description=pdescription) newpoke.put() self.session['pokemon'] = pname doRender(self,"board.htm",{}) # Construct a google big ass table for this data # to display def get(self): que = db.Query(Pokemondata) listing = que.fetch(limit = 12) doRender(self,'http://pokedexapp.appspot.com/?user=cater54321@gmail.com#input', {'listing':listing}) #self.response.out.write( page % "Fred Bloggs") # This is standard Google App Engine stuff - create a WSGI application # framework and set up the routing between URIs and Handlers... application = webapp.WSGIApplication([('/', Pokemondata), ('/json', JSONInterface)], debug=True) def Addlist(): run_wsgi_app(application) if __name__ == "__Addlist__": main() code here </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload