The other problem is that the customer service page at prettylinkpro.com has a redirect and is unavailable, and so sadly I must post this here. 🙁
For months now Pretty Link Pro has stopped working as it once did. Although I’ve added my Twitter account on the pro options page and PrettyLinkPro is still authorized on my Twitter settings, PrliPro will not auto-tweet scheduled posts when they publish. Just to confirm, I’ve authenticated my Twitter account, checked “Create Pretty Links for Posts”, set them to create in a group, “Show Social Network Button Bar on Posts” and “Automatically post to Twitter when a Post is published” both checked.
Also, there used to be a post meta panel that allowed you to customize the tweet of a scheduled post, this is now gone.
How do I fix the plugin so that it will tweet scheduled posts again? My client is pissed.
sorry for the troubles. Looks like twitter just changed their API version, and discontinued the old version instead of keeping it live for legacy code. Anyways, we’ll have this fixed in the next version of Pretty Link, but if you need to get this working now open the …/wp-content/plugins/pretty-link/pro/includes/php/abraham-twitteroauth/PrliTwitterOAuth.php
public $host = “https://api.twitter.com/1/”;
and change it to:
public $host = “https://api.twitter.com/1.1/”;
Oh, well, that was nice of Twitter now wasn’t it? 😉 Thank you for the response cartpauj I have made the change to my client’s site and hopefully we’ll see the difference when her next post goes out, probably tomorrow. I’ll let you know otherwise, but thanks!
I’m afraid the problem persists with scheduled posts not auto-tweeting. If you publish a post regularly then the auto-tweet fires right away, I tested it on my dev site with another Twitter account, so updating the Twitter API folder fixed that much. However if a post is scheduled, the pretty link is not created and an auto-tweet does not go out when the scheduled post goes live. Instead when you edit that post, the Pretty Link meta box shows the following message: “A Pretty Link hasn’t been generated for this entry yet. Click “Update Post” to generate.” You must then click update, but even then an auto-tweet does not fire. The client has to go to the post and click the share button on the social bookmark bar. So we obviously need to look at the logic for tweet creation, do you happen to know where that code resides? Thanks again for your help.
@cartpauj Unfortunately I made the above changes to the file on Friday, but today my client says they still had to update the scheduled post after it went live in order to create the Pretty Link. I’m going to test it on a test site a little later, but until then is there anything else you can think of to fix auto-tweet on scheduled post update? Thanks.
I set up PrLiPro on another site and scheduled a post. The plugin created the Pretty Link when the post went live, it wasn’t doing that previously so that part is fixed. However the plugin did not publish the title and link to Twitter. So perhaps since the API has changed there is some new hook for auto-tweeting?
Also, so I remove and reconnect the Twitter account? Might that help at all?
You can try reconnecting to twitter. I just tested this again myself and it worked fine. The post was scheduled, I checked a few hours later (after it should’ve been published) and it was posted to my twitter account without issue.
I deactivated the Twitter account by clicking the little x next to it, then saved the options. When I returned to the Twitter Options I could see the following error above Add a Twitter Account button:
Warning: Invalid argument supplied for foreach() in /home/danbir5/public_html/lvmb/wp-content/plugins/pretty-link/pro/classes/views/prlipro-options/form.php on line 177
When I clicked the button and authorized the app on Twitter, it returned me to my site. However, it was a white PHP error page with the following errors:
Warning: Invalid argument supplied for foreach() in /home/danbir5/public_html/lvmb/wp-content/plugins/pretty-link/pro/pretty-link-pro.php on line 1642
Warning: Cannot modify header information – headers already sent by (output started at /home/danbir5/public_html/lvmb/wp-content/plugins/pretty-link/pro/pretty-link-pro.php:1642) in /home/danbir5/public_html/lvmb/wp-content/plugins/pretty-link/pro/pretty-link-pro.php on line 1673
Just an update after this occurred, I wonder if it sheds some light. I will schedule another post and update you tomorrow on whether it auto-tweets yet.