You are using greedy matches, you are basically saying: match any character and match them all!
So your url part "-page=2" gets selected, too.
Try using something like this:
admin/keyword=([^-]+)-page...
It excludes the - from the first part. If your keywords could contain a minus, you'd have to...
Yes, it is possible. But there is no way to control a gif, so you'll need two files for every gif, one animated and one that only displays whatever you want to have displayed (e.g. first frame of the gif).
Then add an event handler for mouseover that changes the img src to the animated version...
Well, there are not many cases where the error message describes the problem in a more accurate way. And a simple search with your favorite search engine would've showed many solutions for sure.
You have to use header() before any output. Even a simple space will break it. I guess...
And one more addition:
file_put_contents() will overwrite your file without the proper flags set.
So if you want to log continuously and keep the logged text, use:
<?php
file_put_contents('log.txt', $_GET['text'], FILE_APPEND);
?>
It's not the same format.
The retweet uses statuses/retweet/id while the favorites use favorites/create and you have to send the ID as POST data.
<?php
$tweet->post('favorites/create',array('id'=>$postID));
?>
@a: Print out the your variable (e.g. $retweetResult) to get some status informations. There should be an error message
@b: You're right about the consumer keys. To get access tokens for each user you need to grant the app the rights to post on the account's behalf. Read about oauth/authorize...
No need to apologize. Just keep all the help in mind and share your knowledge in the future like we did. :)
Read Post #9, I explained it there.
An app is nothing more than a script. To use the twitter api you need to register an app and every account you want to retweet to has to grant this app...
That's what he wanted, as far as I understand. He wants to retweet a single post to the accounts from his csv.
In your example he connects as account1, gets the latest tweets that account1 posted and retweets them as account1. That's not very effective.
Don't get me wrong, I like that you're...
I meant the outer loop, where you loop through the user accounts.
If you have five accounts inside accounts.txt you will call $connection->get five times - but you only need it once to get the tweet id.
The same applies to the vars $notweets, $ignore_replies and $include_rts, you're assigning...
1) This variable just stores what ever the connection returns, usually an array with some informations. Might contain some error code if the post fails, but is not necessary for posting.
2) You can't use the same keys for different users. Assign the keys inside the loop.
for(...) {...
To post the tweet you need to connect to twitter using the credentials of the account you want to use, just like you did to get the tweet in first place.
//line from your code:
$connection = getConnectionWithAccessToken($consumerkey, $consumersecret, $accesstoken, $accesstokensecret);
//line to...
You need to set up an application on twitter and every account has to grant this app the right to tweet on their behalf. This is the very first step that has to happen (yeah, you could get credentials for every account and do the login via curl, but that's way more difficult and error prone)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.