Simple Author Box - Version 2.46

Version Description

  • 2022-04-13
  • Fixed author box showing on all post types in some cases
Download this release

Release Info

Developer WebFactory
Plugin Icon 128x128 Simple Author Box
Version 2.46
Comparing to
See all releases

Code changes from version 2.45 to 2.46

Files changed (3) hide show
  1. inc/functions.php +5 -3
  2. readme.txt +4 -1
  3. simple-author-box.php +2 -2
inc/functions.php CHANGED
@@ -12,8 +12,8 @@ if ( ! function_exists( 'wpsabox_author_box' ) ) {
12
 
13
 
14
  function wpsabox_author_box( $saboxmeta = null, $user_id = null) {
15
-
16
- $show = ( is_single() || is_author() || is_archive() );
17
 
18
  /**
19
  * Hook: sabox_check_if_show.
@@ -21,7 +21,9 @@ if ( ! function_exists( 'wpsabox_author_box' ) ) {
21
  * @hooked Simple_Author_Box::check_if_show_archive - 10
22
  */
23
 
24
- $show = apply_filters( 'sabox_check_if_show', $show );
 
 
25
 
26
  if ( $show ) {
27
 
12
 
13
 
14
  function wpsabox_author_box( $saboxmeta = null, $user_id = null) {
15
+ global $post;
16
+ $show = ( is_single() && $post->post_type == 'post' || is_author() || (is_archive() && 1 != $this->options['sab_hide_on_archive']) );
17
 
18
  /**
19
  * Hook: sabox_check_if_show.
21
  * @hooked Simple_Author_Box::check_if_show_archive - 10
22
  */
23
 
24
+ if(is_archive()){
25
+ $show = apply_filters( 'sabox_check_if_show', $show );
26
+ }
27
 
28
  if ( $show ) {
29
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: author box, responsive author box, author profile fields, author social ic
4
  Requires at least: 4.6
5
  Requires PHP: 5.6
6
  Tested up to: 5.9
7
- Stable tag: 2.45
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -48,6 +48,9 @@ Add a responsive author box with social icons to any post. Great author box for
48
 
49
 
50
  == Changelog ==
 
 
 
51
 
52
  = 2.45 =
53
  * 2021-11-28
4
  Requires at least: 4.6
5
  Requires PHP: 5.6
6
  Tested up to: 5.9
7
+ Stable tag: 2.46
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
48
 
49
 
50
  == Changelog ==
51
+ = 2.46 =
52
+ * 2022-04-13
53
+ * Fixed author box showing on all post types in some cases
54
 
55
  = 2.45 =
56
  * 2021-11-28
simple-author-box.php CHANGED
@@ -3,14 +3,14 @@
3
  * Plugin Name: Simple Author Box
4
  * Plugin URI: https://wpauthorbox.com/
5
  * Description: Adds a responsive author box with social icons on any post.
6
- * Version: 2.45
7
  * Author: WebFactory Ltd
8
  * Author URI: https://www.webfactoryltd.com/
9
  * Requires: 4.6
10
  * License: GPLv3 or later
11
  * License URI: http://www.gnu.org/licenses/gpl-3.0.html
12
  * Requires PHP: 5.6
13
- * Tested up to: 5.7
14
 
15
  *
16
  * Copyright 2014-2017 Tiguan office@tiguandesign.com
3
  * Plugin Name: Simple Author Box
4
  * Plugin URI: https://wpauthorbox.com/
5
  * Description: Adds a responsive author box with social icons on any post.
6
+ * Version: 2.46
7
  * Author: WebFactory Ltd
8
  * Author URI: https://www.webfactoryltd.com/
9
  * Requires: 4.6
10
  * License: GPLv3 or later
11
  * License URI: http://www.gnu.org/licenses/gpl-3.0.html
12
  * Requires PHP: 5.6
13
+ * Tested up to: 5.9
14
 
15
  *
16
  * Copyright 2014-2017 Tiguan office@tiguandesign.com