[animated-twitter-slideshow] shortcode in your content section. To add directly to your php template code add echo do_shortcode(\'[animated-twitter-slideshow]\'); directly to the portion of the template you wish to display in.', 'animated-twitter-slideshow' ), 'update-nag' );
?>
'ats-api-key', 'type'=>'text', 'instructions'=>'Enter the Consumer Key for your registered Twitter application. Go to Apps.Twitter.com and follow the instructions from the readme.txt to setup your API Key and Secret below.') );
add_settings_field( 'ats-api-secret', __( 'Twitter Consumer Secret (API Secret)', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-auth-section', $args=array('name'=>'ats-api-secret', 'type'=>'text', 'instructions'=>'Enter the Consumer Secret for your registered Twitter application (see readme.txt).') );
add_settings_field( 'ats-twitter-users-field', __( 'Twitter User', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-display-section', $args=array('name'=>'ats-twitter-users-field', 'type'=>'text', 'instructions'=>'Enter the Twitter User Screen Name to display. Example: @wholahoopmedia.') );
add_settings_field( 'ats-tweet-count', __( 'Max Tweets to Display', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-display-section', $args=array('name'=>'ats-tweet-count', 'type'=>'select', 'items'=>array("1","2","3","4","5","6","7","8","9","10"), 'instructions'=>'Enter the maximum number of tweets (slides) to display. The actual number displayed may be lower due to Twitters calculations, and retweets.') );
add_settings_field( 'ats-slideshow-delay', __( 'Slideshow Delay', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-display-section', $args=array('name'=>'ats-slideshow-delay', 'type'=>'select', 'items'=>array("4","5","6","7","8","9","10"), 'instructions' =>'Select the slideshow delay in seconds.' ) );
add_settings_field( 'ats-cache-timer', __( 'Set Twitter API Cache', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-display-section', $args=array('name'=>'ats-cache-timer', 'type'=>'select', 'items'=>array("15","30","45","60"), 'instructions' =>'Select the cache hold for the Twitter API in minutes. This value ensures that you will not make too many calls to the Twitter API server.' ) );
add_settings_field( 'ats-clear-cache', __( 'Clear Twitter API Cache', 'textdomain' ), array( $this, 'atsPlugInFieldCreate' ), 'ats-settings', 'ats-twitter-display-section', $args=array('name'=>'ats-clear-cache', 'type'=>'clear-cache', 'instructions' =>'Clear the current cache of Twitter tweet responses. Do this when you change/add/remove twitter users to follow.' ) );
}
/**
* function atsDisplaySectionCallback
*/
public function atsDisplaySectionCallback() {
_e( 'Enter all slideshow settings below.', 'textdomain' );
}
public function atsAuthSectionCallback() {
_e( 'Enter your created Twitter App information below.', 'textdomain' );
}
/**
* function atsPlugInFieldCreate
* params: array( string $name, string $type, (opt) array $items, (opt) string $instructions )
*
*/
public function atsPlugInFieldCreate( $args ) {
$settings = (array) get_option( 'ats-settings' );
$field = $args['name'];
$value = esc_attr( $settings[$field] );
if( isset( $args['items'] ) ) { $items = $args['items']; }
//switch on field input type
switch ($args['type']) {
case 'text' :
echo "";
break;
case 'select' :
echo "";
break;
case 'clear-cache' :
echo('');
break;
}
//add instructions if needed
if( isset( $args['instructions'] ) ) {
$instructions = $args['instructions'];
echo "