Beispiel #1
0
 def get(self, request, *args, **kwargs):
     oauth_verifier = request.GET['oauth_verifier']
     if oauth_verifier:
         tr = twitter()
         tr.updateOUAHWithVerifier(oauth_verifier)
         return HttpResponse()
     else:
         return HttpResponseForbidden()
Beispiel #2
0
 def get(self, request, *args, **kwargs):
     tw = twitter()
     test = tw.twitter_instance.search(q='twitter', result_type='popular')
     response = super(keyWordToSentiment, self).get(request, *args, **kwargs)
     response.context_data['test'] = test
     return response