Advertisement
Guest User

Untitled

a guest
Aug 29th, 2014
183
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.42 KB | None | 0 0
  1. class WikiPage(WikiHandler):
  2.     def get(self, wikipath):
  3.         url_path = self.request.path
  4.         wikiarticle = db.GqlQuery("SELECT * FROM WikiArticle WHERE path = :1", url_path)
  5.        
  6.         if wikiarticle.get():
  7.             self.response.write(wikiarticle)
  8.             logging.info('%s', wikiarticle)
  9.  
  10.         else:
  11.            self.response.write(wikiarticle)
  12.            logging.info("Sorry, try again!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement