Quote:
Originally Posted by mykkal
Hey King, how are you?
Please, if you know...I'm just wondering if you know what code I need to change so that the "tweet" title reflects the title of the post "tweeted".
|
For the record, this took 69 lines of code in a preliminary testing stage. With error checking it does error checking in several steps:
- Format Tweet with post title.
- Find length of tweet + link, if under 140, skip to the last number.
- If above 140, it uses the TinyURL API to create a shortened link and recreates the Tweet.
- Rechecks length, if under 140 skip to the last step.
- If above 140, it takes the post title and shrinks it so that the tweet is exactly 140 characters and adds a '...' to the end of the chopped off title.
- Send Tweet
This needs to be coded for thread titles, so it'll be at least another 69 lines of code, compared to the 10 it was before this detailed tweet functionality.