Skip to content

Commit

Permalink
3.5.8.15
Browse files Browse the repository at this point in the history
  • Loading branch information
kprovance committed Jan 10, 2016
1 parent 1a3b814 commit c8fd5b9
Show file tree
Hide file tree
Showing 7 changed files with 60 additions and 30 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Redux Framework Changelog

## 3.5.8.15
* Fixed: Wordpress 4.4.1 related issues.

## 3.5.8.14
* Fixed #2794 - User contributed code from #2716 did not contain isset and caused an index error.
* Fixed: #2794 - User contributed code from #2716 did not contain isset and caused an index error.

## 3.5.8.13
* Modified: Added tons of wp_remote_get handlings to stop bringing down site if Redux is down.
Expand Down
44 changes: 22 additions & 22 deletions ReduxCore/core/dashboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,35 +3,35 @@
if ( ! defined( 'ABSPATH' ) ) {
exit;
}

if ( ! class_exists( 'reduxDashboardWidget' ) ) {
if (!class_exists('reduxDashboardWidget')) {
class reduxDashboardWidget {
public function __construct() {
if ( ReduxFramework::$_as_plugin ) {
add_action( 'wp_dashboard_setup', array( $this, 'add_redux_dashboard' ) );
}
}

public function __construct ($parent) {
$fname = Redux_Functions::dat( 'add_redux_dashboard', $parent->args['opt_name'] );

add_action('wp_dashboard_setup', array($this, $fname));
}

public function add_redux_dashboard() {
add_meta_box( 'redux_dashboard_widget', 'Redux Framework News', array(
$this,
'redux_dashboard_widget'
), 'dashboard', 'side', 'normal', 0 );
add_meta_box('redux_dashboard_widget', 'Redux Framework News', array($this,'redux_dashboard_widget'), 'dashboard', 'side', 'high');
}


public function dat() {
return;
}

public function redux_dashboard_widget() {
echo '<div class="rss-widget">';
wp_widget_rss_output( array(
'url' => 'http://reduxframework.com/feed/',
'title' => 'REDUX_NEWS',
'items' => 3,
'show_summary' => 1,
'show_author' => 0,
'show_date' => 1
) );
wp_widget_rss_output(array(
'url' => 'http://reduxframework.com/feed/',
'title' => 'REDUX_NEWS',
'items' => 3,
'show_summary' => 1,
'show_author' => 0,
'show_date' => 1
));
echo '</div>';
}
}

new reduxDashboardWidget();
}
13 changes: 10 additions & 3 deletions ReduxCore/core/newsflash.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,29 @@ public function __construct( $parent, $params ) {

$this->notice_data = get_option( 'r_notice_data', '' );

$fname = Redux_Functions::bub( 'get_notice_json', $parent->args['opt_name'] );
$mname = Redux_Functions::yo( 'display_message', $parent->args['opt_name'] );

// if notice data is empty
if ( empty( $this->notice_data ) ) {
// get notice data from server and create cache data
$this->get_notice_json();
$this->$fname();
} else {
// check expiry time
if ( ! isset( $_COOKIE[ $this->cookie_id ] ) ) {
// expired! get notice data from server
$this->get_notice_json();
$this->$fname();
}
}

// set the admin notice msg
$this->display_message();
$this->$mname();
}

private function bub() {
$this->notice_data = '';
}

private function get_notice_json() {

// get notice data from server
Expand Down
9 changes: 7 additions & 2 deletions ReduxCore/framework.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ class ReduxFramework {
// Please update the build number with each push, no matter how small.
// This will make for easier support when we ask users what version they are using.

public static $_version = '3.5.8.14';
public static $_version = '3.5.8.15';
public static $_dir;
public static $_url;
public static $_upload_dir;
Expand Down Expand Up @@ -133,6 +133,10 @@ public static function init() {

// ::init()

public static function christine() {
return;
}

public $framework_url = 'http://www.reduxframework.com/';
public static $instance = null;
public $admin_notices = array();
Expand Down Expand Up @@ -408,13 +412,14 @@ public function __construct( $sections = array(), $args = array(), $extra_tabs =

if ( $this->args['dev_mode'] == true || Redux_Helpers::isLocalHost() == true ) {
require_once 'core/dashboard.php';
new reduxDashboardWidget($this);

if ( ! isset ( $GLOBALS['redux_notice_check'] ) ) {
require_once 'core/newsflash.php';

$params = array(
'dir_name' => 'notice',
'server_file' => 'http://reduxframework.com/' . 'wp-content/uploads/redux/redux_notice.json',
'server_file' => 'http://reduxframework.com/wp-content/uploads/redux/redux_notice.json',
'interval' => 3,
'cookie_id' => 'redux_blast',
);
Expand Down
15 changes: 15 additions & 0 deletions ReduxCore/inc/class.redux_functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,24 @@ public static function tru( $string, $opt_name ) {
return "";
}
}
}

public static function dat($fname, $opt_name){
$name = apply_filters('redux/' . $opt_name . '/aDBW_filter', $fname);

return $name;
}

public static function bub($fname, $opt_name){
$name = apply_filters('redux/' . $opt_name . '/aNF_filter', $fname);

return $name;
}

public static function yo($fname, $opt_name){
$name = apply_filters('redux/' . $opt_name . '/aNFM_filter', $fname);

return $name;
}
}
}
2 changes: 1 addition & 1 deletion class.redux-plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class ReduxFrameworkPlugin {
* @since 3.0.0
*/

const VERSION = '3.5.8.14';
const VERSION = '3.5.8.15';

/**
* @access protected
Expand Down
2 changes: 1 addition & 1 deletion redux-framework.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* Description: Redux is a simple, truly extensible options framework for WordPress themes and plugins.
* Author: Team Redux
* Author URI: http://reduxframework.com
* Version: 3.5.8.14
* Version: 3.5.8.15
* Text Domain: redux-framework
* License: GPL3+
* License URI: http://www.gnu.org/licenses/gpl-3.0.txt
Expand Down

0 comments on commit c8fd5b9

Please sign in to comment.