Update modules

This commit is contained in:
Brian Miyaji
2017-02-08 19:16:29 +11:00
parent fa489fb883
commit cb47de74b1
2 changed files with 23 additions and 70 deletions

View File

@@ -74,61 +74,19 @@ class SP_Settings_Modules extends SP_Settings_Page {
</table>
<?php } ?>
<?php if ( ! class_exists( 'SportsPress_Twitter' ) ) { ?>
<?php if ( ! class_exists( 'SportsPress_Twitter' ) || ! class_exists( 'SportsPress_Facebook' ) ) { ?>
<table class="widefat" cellspacing="0">
<thead>
<tr><th>
<strong><?php _e( 'Twitter Module', 'sportspress' ); ?></strong>
<strong><?php _e( 'Get Freebies', 'sportspress' ); ?></strong>
</th></tr>
</thead>
<tbody>
<tr><td>
<ol><li><?php echo str_replace(
array( '[link]', '[/link]' ),
array( '<a target="_blank" href="http://twitter.com/themeboy">', '</a>' ),
__( 'Follow [link]@ThemeBoy[/link] on Twitter.','sportspress' )
); ?></li>
<li><?php echo str_replace(
array( '[link]', '[/link]' ),
array( '<a target="_blank" href="http://tboy.co/tweet">', '</a>' ),
__( 'Help spread the word by tweeting with [link]#SportsPress[/link] and get the Twitter module for free.','sportspress' )
); ?></li>
<li><?php echo str_replace(
array( '[link]', '[/link]' ),
array( '<a target="_blank" href="http://tboy.co/twittermodule">', '</a>' ),
__( '[link]Get the download link[/link].', 'sportspress' )
); ?></li></ol>
<p><?php _e( 'Instant access to exclusive SportsPress extensions and free downloads.', 'sportspress' ); ?></p>
<p class="sp-module-actions">
<span><?php _e( 'Free with tweet', 'sportspress' ); ?></span>
<a class="button" href="http://tboy.co/tweet" target="_blank"><?php _e( 'Tweet', 'sportspress' ); ?></a>
</p>
</td></tr>
</tbody>
</table>
<?php } ?>
<?php if ( ! class_exists( 'SportsPress_Facebook' ) ) { ?>
<table class="widefat" cellspacing="0">
<thead>
<tr><th>
<strong><?php _e( 'Facebook Module', 'sportspress' ); ?></strong>
</th></tr>
</thead>
<tbody>
<tr><td>
<ol><li><?php echo str_replace(
array( '[link]', '[/link]' ),
array( '<a target="_blank" href="https://www.facebook.com/themeboy">', '</a>' ),
__( 'Like [link]ThemeBoy[/link] on Facebook.','sportspress' )
); ?></li>
<li><?php echo str_replace(
array( '[link]', '[/link]' ),
array( '<a target="_blank" href="http://tboy.co/facebookmodule">', '</a>' ),
__( '[link]Get the download link[/link].', 'sportspress' )
); ?></li></ol>
<p class="sp-module-actions">
<span><?php _e( 'Free with Like', 'sportspress' ); ?></span>
<a class="button" href="http://tboy.co/facebook" target="_blank"><?php _e( 'Visit Page', 'sportspress' ); ?></a>
<span><?php _e( 'Create a free account', 'sportspress' ); ?></span>
<a class="button" href="http://tboy.co/account" target="_blank"><?php _e( 'Sign Up', 'sportspress' ); ?></a>
</p>
</td></tr>
</tbody>
@@ -267,17 +225,14 @@ class SP_Settings_Modules extends SP_Settings_Page {
<i class="<?php echo sp_array_value( $module, 'icon', 'dashicons dashicons-admin-generic' ); ?>"></i>
<?php echo sp_array_value( $module, 'label', $id ); ?>
</span>
<?php if ( isset( $module['desc'] ) && ! array_key_exists( 'action', $module ) ) { ?>
<?php if ( isset( $module['desc'] ) ) { ?>
<span class="sp-desc">
<?php echo $module['desc']; ?>
<?php if ( array_key_exists( 'link', $module ) && ! array_key_exists( 'action', $module ) ) { ?>
<?php if ( array_key_exists( 'link', $module ) ) { ?>
<a href="<?php echo $module['link']; ?>" target="_blank"><?php echo sp_array_value( $module, 'action', __( 'Learn more', 'sportspress' ) ); ?></a>
<?php } ?>
</span>
<?php } ?>
<?php if ( array_key_exists( 'link', $module ) && array_key_exists( 'action', $module ) ) { ?>
<a class="button" href="<?php echo $module['link']; ?>" target="_blank"><?php echo sp_array_value( $module, 'action', __( 'Learn more', 'sportspress' ) ); ?></a>
<?php } ?>
</td></tr>
<?php } else { ?>
<tr><td>

View File

@@ -33,28 +33,28 @@ class SP_Modules {
'label' => __( 'Scoreboard', 'sportspress' ),
'class' => 'SportsPress_Scoreboard',
'icon' => 'sp-icon-scoreboard',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/scoreboard/',
'desc' => __( 'Display multiple event results in a horizontal scoreboard.', 'sportspress' ),
),
'match_stats' => array(
'label' => __( 'Match Stats', 'sportspress' ),
'class' => 'SportsPress_Match_Stats',
'icon' => 'sp-icon-statistics',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/match-stats/',
'desc' => __( 'Display head-to-head team comparison charts in events.', 'sportspress' ),
),
'timelines' => array(
'label' => __( 'Timelines', 'sportspress' ),
'class' => 'SportsPress_Timelines',
'icon' => 'sp-icon-timeline',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/timelines/',
'desc' => __( 'Display a visual timeline of player performance in events.', 'sportspress' ),
),
'tournaments' => array(
'label' => __( 'Tournaments', 'sportspress' ),
'class' => 'SportsPress_Tournaments',
'icon' => 'sp-icon-tournament',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/tournaments/',
'desc' => __( 'Schedule tournaments and create interactive playoff brackets.', 'sportspress' ),
),
),
@@ -68,21 +68,21 @@ class SP_Modules {
'label' => __( 'League Menu', 'sportspress' ),
'class' => 'SportsPress_League_Menu',
'icon' => 'sp-icon-menu',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/league-menu/',
'desc' => __( 'Add a global navigation bar to display logos that link to each team.', 'sportspress' ),
),
'team_colors' => array(
'label' => __( 'Team Colors', 'sportspress' ),
'class' => 'SportsPress_Team_Colors',
'icon' => 'sp-icon-color',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/team-colors/',
'desc' => __( 'Create a custom color palette for each team.', 'sportspress' ),
),
'team_access' => array(
'label' => __( 'Team Access', 'sportspress' ),
'class' => 'SportsPress_Team_Access',
'icon' => 'sp-icon-key',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/team-access/',
'desc' => __( 'Limit user access to data that is related to their team.', 'sportspress' ),
),
),
@@ -96,7 +96,7 @@ class SP_Modules {
'label' => __( 'Directories', 'sportspress' ),
'class' => 'SportsPress_Staff_Directories',
'icon' => 'sp-icon-archive',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/directories/',
'desc' => __( 'Organize and display staff in list and gallery layouts.', 'sportspress' ),
),
),
@@ -110,14 +110,14 @@ class SP_Modules {
'label' => __( 'Branding', 'sportspress' ),
'class' => 'SportsPress_Branding',
'icon' => 'sp-icon-sportspress',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/branding/',
'desc' => __( 'Instantly rebrand the dashboard with your own logo and colors.', 'sportspress' ),
),
'duplicator' => array(
'label' => __( 'Duplicator', 'sportspress' ),
'class' => 'SportsPress_Duplicator',
'icon' => 'sp-icon-copy',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/duplicator/',
'desc' => __( 'Clone anything with just one click. Great for creating multiple events.', 'sportspress' ),
),
),
@@ -125,26 +125,24 @@ class SP_Modules {
'twitter' => array(
'label' => __( 'Twitter', 'sportspress' ),
'class' => 'SportsPress_Twitter',
'action' => __( 'Tweet #SportsPress', 'sportspress' ),
'link' => 'http://tboy.co/tweet',
'tip' => __( 'Help spread the word by tweeting with #SportsPress and get the Twitter module for free.', 'sportspress' ),
'icon' => 'dashicons dashicons-twitter',
'link' => 'https://www.themeboy.com/sportspress-extensions/twitter/',
'desc' => __( 'Add a Twitter feed to team, player, and staff pages.', 'sportspress' ),
'tip' => __( 'Free', 'sportspress' ),
),
'facebook' => array(
'label' => __( 'Facebook', 'sportspress' ),
'class' => 'SportsPress_Facebook',
'action' => __( 'Like Us on Facebook', 'sportspress' ),
'link' => 'http://tboy.co/facebook',
'tip' => __( 'Help spread the word by liking our Page and get the Facebook module for free.', 'sportspress' ),
'icon' => 'dashicons dashicons-facebook',
'link' => 'https://www.themeboy.com/sportspress-extensions/facebook/',
'desc' => __( 'Add a Facebook Page widget to embed and promote each team.', 'sportspress' ),
'tip' => __( 'Free', 'sportspress' ),
),
'sponsors' => array(
'label' => __( 'Sponsors', 'sportspress' ),
'class' => 'SportsPress_Sponsors',
'icon' => 'sp-icon-megaphone',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/sponsors/',
'desc' => __( 'Attract sponsors by offering them advertising space on your website.', 'sportspress' ),
),
),
@@ -155,7 +153,7 @@ class SP_Modules {
'label' => __( 'Multisite', 'sportspress' ),
'class' => 'SportsPress_Multisite',
'icon' => 'sp-icon-globe',
'link' => 'http://tboy.co/pro',
'link' => 'https://www.themeboy.com/sportspress-extensions/multisite/',
'desc' => __( 'Manage multiple sports and display different widgets all on one site.', 'sportspress' ),
);
}