diff --git a/includes/options.php b/includes/options.php index f5b8cb1..a101275 100755 --- a/includes/options.php +++ b/includes/options.php @@ -26,11 +26,11 @@ static function wpfc_validate_options( $input ) { unset( $input['sm_do_not_catch'] ); } else { update_option( '_sm_recovery_do_not_catch', '0' ); - } + } - if ( SermonManager::getOption( 'archive_slug' ) != $input['archive_slug'] || - SermonManager::getOption( 'common_base_slug' ) != $input['common_base_slug'] || - SermonManager::getOption( 'preacher_label' ) != $input['preacher_label'] ) { + if ( SermonManager::getOption( 'archive_slug' ) != $input['archive_slug'] || + SermonManager::getOption( 'common_base_slug' ) != $input['common_base_slug'] || + SermonManager::getOption( 'preacher_label' ) != $input['preacher_label'] ) { update_option( 'sm_flush_rewrite_rules', '1' ); } @@ -43,7 +43,7 @@ static function wpfc_validate_options( $input ) { * @since 2.5.2 */ function maybe_flush_rewrite_rules() { - if ( boolval( get_option( 'sm_flush_rewrite_rules' ) ) ) { + if ( (bool) get_option( 'sm_flush_rewrite_rules' ) ) { flush_rewrite_rules(); update_option( 'sm_flush_rewrite_rules', '0' ); } @@ -167,17 +167,21 @@ function wpfc_sermon_options_render_form() { -

+

+

@@ -186,13 +190,16 @@ function wpfc_sermon_options_render_form() {
-

+

+

' . esc_html__( 'Sign up', 'sermon-manager-for-wordpress' ) . '' ); ?>

  - + target="_blank" + class="button-secondary">  +
@@ -201,7 +208,9 @@ function wpfc_sermon_options_render_form() {
-

+

+ +

- ' . esc_html__( 'knowledge base', 'sermon-manager-for-wordpress' ) . '' ); ?> + ' . esc_html__( 'knowledge base', 'sermon-manager-for-wordpress' ) . '' ); ?>
-

+

+ +

+ target="_blank" + class="button-secondary">
@@ -241,7 +253,9 @@ function wpfc_sermon_options_render_form() {
-

+

+ +

@@ -279,7 +293,7 @@ function wpfc_sermon_options_render_form() {
@@ -371,7 +385,9 @@ function wpfc_sermon_options_render_form() {
-

+

+ +

@@ -411,11 +427,11 @@ function wpfc_sermon_options_render_form() { ESV', - 'NET', - 'KJV', - 'LEB', - '' . esc_html__( 'bib.ly', 'sermon-manager-for-wordpress' ) . '' ); ?> + 'ESV', + 'NET', + 'KJV', + 'LEB', + '' . esc_html__( 'bib.ly', 'sermon-manager-for-wordpress' ) . '' ); ?>
ESV' ); ?>
@@ -426,7 +442,9 @@ function wpfc_sermon_options_render_form() {
-

+

+ +

@@ -462,7 +480,7 @@ function wpfc_sermon_options_render_form() {
@@ -472,7 +490,7 @@ function wpfc_sermon_options_render_form() { @@ -482,7 +500,7 @@ function wpfc_sermon_options_render_form() { @@ -492,12 +510,12 @@ function wpfc_sermon_options_render_form() { @@ -517,7 +535,7 @@ function wpfc_sermon_options_render_form() { @@ -540,7 +558,7 @@ function wpfc_sermon_options_render_form() {

- ' . htmlspecialchars( '©' ) . ''); ?> + ' . htmlspecialchars( '©' ) . '' ); ?>

@@ -553,7 +571,7 @@ function wpfc_sermon_options_render_form() { + placeholder="">

@@ -565,7 +583,7 @@ function wpfc_sermon_options_render_form() {
@@ -578,7 +596,7 @@ function wpfc_sermon_options_render_form() { @@ -676,11 +694,11 @@ class="itunes_cover_image_field"
+ $archive_slug = $options['archive_slug']; + if ( empty( $archive_slug ) ) { + $archive_slug = 'sermons'; + } + echo home_url( '/' ) . $archive_slug; ?>/feed/"/>

' . esc_html__( 'Feed Validator', 'sermon-manager-for-wordpress' ) . '' ); ?> diff --git a/includes/shortcodes.php b/includes/shortcodes.php index b0a8914..988f880 100755 --- a/includes/shortcodes.php +++ b/includes/shortcodes.php @@ -302,7 +302,7 @@ public function displayImages( $atts = array() ) { $args = shortcode_atts( $args, $atts, 'sermon_images' ); // convert to bool - $args['show_description'] = boolval( $args['show_description'] ); + $args['show_description'] = (bool) $args['show_description']; // check if we are using a SM taxonomy, and if we are, convert to valid taxonomy name if ( $this->convertTaxonomyName( $args['display'], true ) ) { @@ -425,11 +425,11 @@ function displayLatestSeriesImage( $atts = array() ) { $image = wp_get_attachment_image( $series_image_id, $args['size'], false, array( 'class' => $image_class ) ); $title = $description = ''; - if ( boolval( $args['show_title'] ) === true ) { + if ( (bool) $args['show_title'] === true ) { $title = $latest_series->name; $title = '<' . $args['title_wrapper'] . ' class="' . $title_class . '">' . $title . ''; } - if ( boolval( $args['show_desc'] ) === true ) { + if ( (bool) $args['show_desc'] === true ) { $description = '

' . wpautop( $latest_series->description ) . '
'; } diff --git a/includes/sm-legacy-php-functions.php b/includes/sm-legacy-php-functions.php deleted file mode 100644 index 6cb377c..0000000 --- a/includes/sm-legacy-php-functions.php +++ /dev/null @@ -1,13 +0,0 @@ -