Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def get():
- # Get data from source
- db.get(some_id)
- # Do work on data here
- if header.accept == "text/html":
- render('data.html', data)
- elif header.accept == "application/json":
- render('data.json', data)
Add Comment
Please, Sign In to add comment