Simple Custom Post Order - Version 2.4.6

Version Description

Download this release

Release Info

Developer machothemes
Plugin Icon wp plugin Simple Custom Post Order
Version 2.4.6
Comparing to
See all releases

Code changes from version 2.4.5 to 2.4.6

class-colorlib-dashboard-widget-extend-feed.php DELETED
@@ -1,90 +0,0 @@
1
- <?php
2
-
3
- if ( ! class_exists( 'Colorlib_Dashboard_Widget_Extend_Feed' ) ) {
4
-
5
- class Colorlib_Dashboard_Widget_Extend_Feed {
6
-
7
- public function __construct() {
8
-
9
- // Actions.
10
- add_action( 'wp_feed_options', array( $this, 'dashboard_update_feed_urls' ), 10, 2 );
11
-
12
- // Filters.
13
- add_filter( 'dashboard_secondary_items', array( $this, 'dashboard_items_count' ) );
14
-
15
- }
16
-
17
- public function dashboard_items_count() {
18
-
19
- /**
20
- * Apply the filters am_dashboard_feed_count for letting an admin
21
- * override this count.
22
- */
23
- return (int) apply_filters( 'colorlib_dashboard_feed_count', 6 );
24
- }
25
-
26
- public function dashboard_update_feed_urls( $feed, $url ) {
27
-
28
- global $pagenow;
29
-
30
- // Return early if not on the right page.
31
- if ( 'admin-ajax.php' !== $pagenow ) {
32
- return;
33
- }
34
-
35
- /**
36
- * Return early if not on the right feed.
37
- * We want to modify the feed URLs only for the
38
- * WordPress Events & News Dashboard Widget
39
- */
40
- if ( is_array( $url ) ) {
41
- if ( ! in_array( 'https://planet.wordpress.org/feed/', $url ) ) {
42
- return;
43
- }
44
- }else{
45
- if ( strpos( $url, 'planet.wordpress.org' ) === false ) {
46
- return;
47
- }
48
- }
49
-
50
- // Build the feed sources.
51
- $all_feed_urls = $this->get_feed_urls( $url );
52
-
53
- // Update the feed sources.
54
- $feed->set_feed_url( $all_feed_urls );
55
- }
56
-
57
- public function get_feed_urls( $url ) {
58
-
59
- // Initialize the feeds array.
60
- $feed_urls = array( $url );
61
-
62
- $check = get_transient( 'colorlib_dashboard_feed' );
63
- $feeds = array();
64
- if ( ! $check ) {
65
-
66
- $feed_working = 'not-working';
67
-
68
- // Load SimplePie Instance
69
- $feed = fetch_feed( array( 'https://colorlib.com/wp/feed/' ) );
70
-
71
- // TODO report error when is an error loading the feed
72
- if ( ! is_wp_error( $feed ) ) {
73
- $feed_urls[] = 'https://colorlib.com/wp/feed/';
74
- $feed_working = 'working';
75
- }
76
-
77
- set_transient( 'colorlib_dashboard_feed', $feed_working, 12 * HOUR_IN_SECONDS );
78
-
79
- }elseif ( 'working' == $check ) {
80
- $feed_urls[] = 'https://colorlib.com/wp/feed/';
81
- }
82
-
83
- // Return the feed URLs.
84
- return array_unique( $feed_urls );
85
- }
86
- }
87
-
88
- // Create an instance.
89
- new Colorlib_Dashboard_Widget_Extend_Feed();
90
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: custom post order, post order, js post order, page order, posts order, cat
4
  Requires at least: 4.6
5
  Requires PHP: 5.6
6
  Tested up to: 5.2
7
- Stable tag: 2.4.5
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -35,6 +35,10 @@ An answer to that question.
35
  3. Settings
36
 
37
  == Changelog ==
 
 
 
 
38
 
39
  = Version 2.4.5 =
40
  * Added 2 action hooks that trigger at `update_menu_order_tags` and `update_menu_order` ( https://github
4
  Requires at least: 4.6
5
  Requires PHP: 5.6
6
  Tested up to: 5.2
7
+ Stable tag: 2.4.6
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
35
  3. Settings
36
 
37
  == Changelog ==
38
+
39
+ = Version 2.4.6 =
40
+ * Removed dashboard news widget
41
+
42
 
43
  = Version 2.4.5 =
44
  * Added 2 action hooks that trigger at `update_menu_order_tags` and `update_menu_order` ( https://github
simple-custom-post-order.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Simple Custom Post Order
4
  * Plugin URI: https://wordpress.org/plugins-wp/simple-custom-post-order/
5
  * Description: Order Items (Posts, Pages, and Custom Post Types) using a Drag and Drop Sortable JavaScript.
6
- * Version: 2.4.5
7
  * Author: Colorlib
8
  * Author URI: https://colorlib.com/
9
  * Tested up to: 5.2
@@ -36,7 +36,7 @@
36
 
37
  define('SCPORDER_URL', plugins_url('', __FILE__));
38
  define('SCPORDER_DIR', plugin_dir_path(__FILE__));
39
- define('SCPORDER_VERSION', '2.4.5');
40
 
41
  $scporder = new SCPO_Engine();
42
 
@@ -597,6 +597,4 @@ function scporder_uninstall_db() {
597
  $result = $wpdb->query($query);
598
  }
599
  delete_option('scporder_install');
600
- }
601
-
602
- require_once 'class-colorlib-dashboard-widget-extend-feed.php';
3
  * Plugin Name: Simple Custom Post Order
4
  * Plugin URI: https://wordpress.org/plugins-wp/simple-custom-post-order/
5
  * Description: Order Items (Posts, Pages, and Custom Post Types) using a Drag and Drop Sortable JavaScript.
6
+ * Version: 2.4.6
7
  * Author: Colorlib
8
  * Author URI: https://colorlib.com/
9
  * Tested up to: 5.2
36
 
37
  define('SCPORDER_URL', plugins_url('', __FILE__));
38
  define('SCPORDER_DIR', plugin_dir_path(__FILE__));
39
+ define('SCPORDER_VERSION', '2.4.6');
40
 
41
  $scporder = new SCPO_Engine();
42
 
597
  $result = $wpdb->query($query);
598
  }
599
  delete_option('scporder_install');
600
+ }