Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
prompt the user for tweet text and return it urlencoded
import urllib
def encode_tweet(tweet):
query = {"status": tweet}
return base_url+urllib.urlencode(query)
if __name__ == '__main__':
tweet = raw_input("paste or type a tweet to encode: ")
print ""
print encode_tweet(tweet)
print ""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.