Rotating Tweets (Twitter widget and shortcode) - Version 1.3.13

Version Description

Includes an important upgrade needed for Rotating Tweets to keep working after March 2013. Supports version 1.1 of the Twitter API. Fixed problem with hashtags.

=

Download this release

Release Info

Developer mpntod
Plugin Icon wp plugin Rotating Tweets (Twitter widget and shortcode)
Version 1.3.13
Comparing to
See all releases

Code changes from version 1.3.12 to 1.3.13

Files changed (2) hide show
  1. readme.txt +23 -6
  2. rotatingtweets.php +2 -2
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
4
  Tags: shortcode,widget,twitter,rotating,rotate,rotator,tweet,tweets,animation,jquery,jquery cycle,cycle,multilingual
5
  Requires at least: 2.6
6
  Tested up to: 3.5
7
- Stable tag: 1.3.12
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -31,7 +31,7 @@ Currently the following languages are available:
31
  * Italian *(basic tweet display only)*
32
  * Dutch *(basic tweet display only)*
33
 
34
- If you have made the plug-in work in your language, please send the translations you'd like to see or, even better, the relevant [gettext PO and MO files](http://codex.wordpress.org/I18n_for_WordPress_Developers) to [me](http://www.martintod.org.uk/contact-martin/) and I will then share them with everyone else. You can download [the latest POT file](http://plugins.svn.wordpress.org/rotatingtweets/trunk/languages/rotatingtweets.pot), and [PO files in each language](http://plugins.svn.wordpress.org/rotatingtweets/trunk/languages/) from this site. You may find [Poedit](http://www.poedit.net/) rather useful for translation and creation of PO and MO files.
35
 
36
  If you'd like to see what the plug-in looks like in action, you can [see the plug-in working here](http://www.martintod.org.uk/2012/05/29/new-twitter-plugin-to-show-tweets-in-rotation/).
37
 
@@ -95,18 +95,35 @@ You can do this by going to the `rotatingtweets/css` directory and renaming `you
95
  = The Rotating Tweets are not rotating. What can I do? =
96
  This normally happens if there is more than one copy of `jQuery` installed on a page - or more than one copy of `jQuery.cycle`.
97
 
98
- To see if this is the case, you can search the HTML on your website to see if either script is called more than once. The quickest way is to search the page for `jquery` and look out for lines that contain `jquery.min.js` or `jquery.cycle.all.min.js`.
 
 
 
 
 
99
 
100
  The problem is that the second (or third) copy of the script overwrites all previous versions and the scripts that go with them. This is particularly likely to happen with old templates or plug-ins.
101
 
102
- If this is the case, the first thing to check is that you have upgraded your template or your plug-in to the latest version.
 
 
 
 
 
 
 
 
 
 
103
 
104
- If this still doesn't work, please let me know which plug-in or template is causing the problem and I'll see if I can build a fix into the next version of Rotating Tweets.
105
  == Upgrade notice ==
106
- = 1.3.12 =
107
  Includes an important upgrade needed for Rotating Tweets to keep working after March 2013. Supports version 1.1 of the Twitter API. Fixed problem with hashtags.
108
 
109
  == Changelog ==
 
 
 
110
  = 1.3.12 =
111
  Removes accents from screen names (and otherwise cleans them up). Add test option (currently for shortcodes only) to access favorites. Solves clash between PECL OAuth library and the Rotating Tweets OAuth library.
112
 
4
  Tags: shortcode,widget,twitter,rotating,rotate,rotator,tweet,tweets,animation,jquery,jquery cycle,cycle,multilingual
5
  Requires at least: 2.6
6
  Tested up to: 3.5
7
+ Stable tag: 1.3.13
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
31
  * Italian *(basic tweet display only)*
32
  * Dutch *(basic tweet display only)*
33
 
34
+ If you have made the plug-in work in your language, please send the translations you'd like to see or, even better, the relevant [gettext PO and MO files](http://codex.wordpress.org/I18n_for_WordPress_Developers) to [me](http://www.martintod.org.uk/contact-martin/) and I will then share them with everyone else. You can download [the latest POT file](http://plugins.svn.wordpress.org/rotatingtweets/trunk/languages/rotatingtweets.pot), and [PO files in each language](http://plugins.svn.wordpress.org/rotatingtweets/trunk/languages/) from this site. You may find [Poedit](http://www.poedit.net/) rather useful for translation and creation of PO and MO files - although the PO files themselves are quite simple text files and can be edited in Notepad or [Notepad++](http://notepad-plus-plus.org/).
35
 
36
  If you'd like to see what the plug-in looks like in action, you can [see the plug-in working here](http://www.martintod.org.uk/2012/05/29/new-twitter-plugin-to-show-tweets-in-rotation/).
37
 
95
  = The Rotating Tweets are not rotating. What can I do? =
96
  This normally happens if there is more than one copy of `jQuery` installed on a page - or more than one copy of `jQuery.cycle`.
97
 
98
+ To see if this is the case, search the HTML on your website to see if either script is called more than once. To do this:
99
+
100
+ 1. Open the page.
101
+ 1. Right click and select 'View Page Source' or 'View Source'
102
+ 1. Hit `[CTRL]+F` and search for `jquery`
103
+ 1. Look out for lines that contain `jquery.min.js` or `jquery.cycle.all.min.js`. Neither script should appear more than once.
104
 
105
  The problem is that the second (or third) copy of the script overwrites all previous versions and the scripts that go with them. This is particularly likely to happen with old templates or plug-ins.
106
 
107
+ If this is the case:
108
+
109
+ 1. Check is that you have upgraded your template or your plug-in to the latest version.
110
+ 1. If this still doesn't work, please let me know which plug-in or template is causing the problem and I'll see if I can build a fix into the next version of Rotating Tweets.
111
+
112
+ If there is only one copy of `jquery` and of `jquery.cycle` on your page, the best way to look for the problem is to open the 'console'. To do this:
113
+
114
+ 1. Press `[F12]` (in Chrome or IE) or `[CTRL]+[SHIFT]+K` (in Firefox)
115
+ 1. Load the page where you have a problem
116
+ 1. In Chrome or IE, select the tab marked 'console'.
117
+ 1. Read the diagnostics and look for any problems that relate to JavaScript. This will normally tell you which JavaScript (if any) is having problems.
118
 
 
119
  == Upgrade notice ==
120
+ = 1.3.13 =
121
  Includes an important upgrade needed for Rotating Tweets to keep working after March 2013. Supports version 1.1 of the Twitter API. Fixed problem with hashtags.
122
 
123
  == Changelog ==
124
+ = 1.3.13 =
125
+ Strips `@` from screen names to avoid API problems.
126
+
127
  = 1.3.12 =
128
  Removes accents from screen names (and otherwise cleans them up). Add test option (currently for shortcodes only) to access favorites. Solves clash between PECL OAuth library and the Rotating Tweets OAuth library.
129
 
rotatingtweets.php CHANGED
@@ -2,7 +2,7 @@
2
  /*
3
  Plugin Name: Rotating Tweets (Twitter widget & shortcode)
4
  Description: Replaces a shortcode such as [rotatingtweets screen_name='your_twitter_name'], or a widget, with a rotating tweets display
5
- Version: 1.3.12
6
  Text Domain: rotatingtweets
7
  Author: Martin Tod
8
  Author URI: http://www.martintod.org.uk
@@ -569,7 +569,7 @@ function rotatingtweets_call_twitter_API($command,$options = NULL,$api = NULL )
569
  # Get the latest data from Twitter (or from a cache if it's been less than 2 minutes since the last load)
570
  function rotatingtweets_get_tweets($tw_screen_name,$tw_include_rts,$tw_exclude_replies,$tw_get_favorites = FALSE) {
571
  # Clear up variables
572
- $tw_screen_name = urlencode(trim(remove_accents($tw_screen_name)));
573
  $cache_delay = 120;
574
  if($tw_include_rts != 1) $tw_include_rts = 0;
575
  if($tw_exclude_replies != 1) $tw_exclude_replies = 0;
2
  /*
3
  Plugin Name: Rotating Tweets (Twitter widget & shortcode)
4
  Description: Replaces a shortcode such as [rotatingtweets screen_name='your_twitter_name'], or a widget, with a rotating tweets display
5
+ Version: 1.3.13
6
  Text Domain: rotatingtweets
7
  Author: Martin Tod
8
  Author URI: http://www.martintod.org.uk
569
  # Get the latest data from Twitter (or from a cache if it's been less than 2 minutes since the last load)
570
  function rotatingtweets_get_tweets($tw_screen_name,$tw_include_rts,$tw_exclude_replies,$tw_get_favorites = FALSE) {
571
  # Clear up variables
572
+ $tw_screen_name = urlencode(trim(remove_accents(str_replace('@','',$tw_screen_name))));
573
  $cache_delay = 120;
574
  if($tw_include_rts != 1) $tw_include_rts = 0;
575
  if($tw_exclude_replies != 1) $tw_exclude_replies = 0;