def GET(self, id): flattr = Flattr() if id == "": id = "1" video = flattr.getVideoById(id) if video is None or video.embeddedcode == "": return "No Oembed data found for that flattr thing!" else: return render.single("Flattr Video Browser", "Flattr Video Browser", "A Flattr API proof of concept", video)
def GET(self, id): flattr = Flattr() if id == "": video = flattr.getRandomVideo(True) thingid = video.thingid return web.seeother('/movie/'+str(thingid)) else: video = flattr.getVideoById(id, True) if video is None or video.embeddedcode == "": return "No Oembed data found for that flattr thing!" else: return renderStatic.movie("Flattr Video Browser", "Flattr Video Browser", "A Flattr API proof of concept", video)