[ci skip]
This commit is contained in:
Mike Helmick 2013-05-29 11:50:23 -04:00
parent 6e1dc6b9bc
commit 14b268e560

View file

@ -138,7 +138,7 @@ except TwythonError as e:
print e print e
``` ```
#### Posting a Status with an Image ##### Posting a Status with an Image
```python ```python
from twython import Twython from twython import Twython
@ -155,15 +155,14 @@ photo = open('/path/to/file/image.jpg', 'rb')
t.update_status_with_media(media=photo, status='Check out my image!') t.update_status_with_media(media=photo, status='Check out my image!')
``` ```
#### Posting a Status with an Editing Image *(This example resizes an image)* ##### Posting a Status with an Editing Image *(This example resizes an image)*
```python ```python
from twython import Twython from twython import Twython
t = Twython(app_key, app_secret, t = Twython(app_key, app_secret,
oauth_token, oauth_token_secret) oauth_token, oauth_token_secret)
# Like I said in the previous section, you can pass any object that has a # Like said in the previous section, you can pass any object that has a read() method
# read() method
# Assume you are working with a JPEG # Assume you are working with a JPEG