Version Description
- Added meta links
- Updated plugin's about page
- Added 'featured themes' and 'priority support' panels
Download this release
Release Info
Developer | Cryout Creations |
Plugin | Cryout Serious Theme Settings |
Version | 0.5.8 |
Comparing to | |
See all releases |
Code changes from version 0.5.7 to 0.5.8
- cryout-theme-settings.php +74 -66
- inc/extra.php +182 -0
- inc/nirvana.php +5 -1
- inc/parabola.php +6 -0
- inc/settings.php +56 -37
- inc/tempera.php +6 -0
- media/anima.jpg +0 -0
- media/fluida.jpg +0 -0
- media/mantra.jpg +0 -0
- media/nirvana.jpg +0 -0
- media/parabola.jpg +0 -0
- media/priority-support.jpg +0 -0
- media/septera.jpg +0 -0
- media/tempera.jpg +0 -0
- media/verbosa.jpg +0 -0
- readme.txt +7 -2
- style.css +33 -0
cryout-theme-settings.php
CHANGED
@@ -2,8 +2,8 @@
|
|
2 |
/*
|
3 |
Plugin Name: Cryout Serious Theme Settings
|
4 |
Plugin URI: https://www.cryoutcreations.eu/serious-theme-settings
|
5 |
-
Description: This plugin is designed to restore our theme's settings page functionality after the enforcement of the Customize-based theme settings. It is only compatible with and will only function when one of our themes is active: Nirvana, Parabola or
|
6 |
-
Version: 0.5.
|
7 |
Author: Cryout Creations
|
8 |
Author URI: https://www.cryoutcreations.eu
|
9 |
License: GPLv3
|
@@ -11,11 +11,11 @@
|
|
11 |
*/
|
12 |
|
13 |
class Cryout_Theme_Settings {
|
14 |
-
public $version = "0.5.
|
15 |
public $settings = array();
|
16 |
-
|
17 |
private $status = 0; // 0 = inactive, 1 = active, 2 = good theme, wrong version, 3 = wrong theme, 4 = compatibility for wp4.4, 5 = theme requires update
|
18 |
-
|
19 |
private $supported_themes = array(
|
20 |
'nirvana' => '1.2',
|
21 |
'tempera' => '1.4',
|
@@ -33,73 +33,73 @@ class Cryout_Theme_Settings {
|
|
33 |
private $slug = 'cryout-theme-settings';
|
34 |
private $title = '';
|
35 |
public $current_theme = array();
|
|
|
36 |
public $renamed_theme = false;
|
37 |
-
|
38 |
public function __construct(){
|
39 |
-
add_action( 'init', array( $this, 'register' ) );
|
40 |
} // __construct()
|
41 |
|
42 |
public function register(){
|
43 |
-
|
44 |
$this->title = __( 'Cryout Serious Theme Settings', 'cryout-theme-settings' );
|
45 |
if ( $this->supported_theme() ):
|
46 |
-
|
47 |
switch ($this->status):
|
48 |
case 1: // restore theme settings
|
49 |
-
|
50 |
include_once( plugin_dir_path( __FILE__ ) . 'inc/' . strtolower($this->current_theme['slug']) . '.php' );
|
51 |
-
|
52 |
-
break;
|
53 |
-
case 4: // repair wrong headings
|
54 |
-
|
55 |
-
add_action( '
|
56 |
-
|
57 |
break;
|
58 |
-
|
59 |
-
default:
|
60 |
break;
|
61 |
endswitch;
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
$cryout_theme_settings_slug = plugin_basename(__FILE__);
|
69 |
-
add_filter( 'plugin_action_links_'.$cryout_theme_settings_slug, array( $this, 'settings_link' ) );
|
70 |
add_action( 'admin_menu', array( $this, 'settings_menu' ) );
|
71 |
-
|
|
|
72 |
} // register()
|
73 |
-
|
74 |
function supported_theme(){
|
75 |
global $wp_version;
|
76 |
-
|
77 |
$current_theme_slug = strtolower( wp_get_theme()->Template );
|
78 |
$current_theme_version = wp_get_theme($current_theme_slug)->Version;
|
79 |
-
|
80 |
if (!in_array( $current_theme_slug, array_keys( $this->supported_themes) )) {
|
81 |
// theme slug does not match supported themes
|
82 |
// perform additional checks for theme constants
|
83 |
-
|
84 |
if (defined('MANTRA_VERSION')) {
|
85 |
if ($current_theme_slug != 'mantra') $this->renamed_theme = true;
|
86 |
$current_theme_slug = 'mantra';
|
87 |
-
$current_theme_version = MANTRA_VERSION;
|
88 |
}
|
89 |
if (defined('PARABOLA_VERSION')) {
|
90 |
if ($current_theme_slug != 'parabola') $this->renamed_theme = true;
|
91 |
$current_theme_slug = 'parabola';
|
92 |
-
$current_theme_version = PARABOLA_VERSION;
|
93 |
}
|
94 |
if (defined('TEMPERA_VERSION')) {
|
95 |
if ($current_theme_slug != 'tempera') $this->renamed_theme = true;
|
96 |
$current_theme_slug = 'tempera';
|
97 |
-
$current_theme_version = TEMPERA_VERSION;
|
98 |
}
|
99 |
if (defined('NIRVANA_VERSION')) {
|
100 |
if ($current_theme_slug != 'nirvana') $this->renamed_theme = true;
|
101 |
$current_theme_slug = 'nirvana';
|
102 |
-
$current_theme_version = NIRVANA_VERSION;
|
103 |
}
|
104 |
if (defined('_CRYOUT_THEME_NAME')) {
|
105 |
if ($current_theme_slug != _CRYOUT_THEME_NAME) $this->renamed_theme = true;
|
@@ -107,19 +107,19 @@ class Cryout_Theme_Settings {
|
|
107 |
if (defined('_CRYOUT_THEME_VERSION')) $current_theme_version = _CRYOUT_THEME_VERSION;
|
108 |
}
|
109 |
} // end additional checks
|
110 |
-
|
111 |
$this->current_theme = array(
|
112 |
-
'slug' => $current_theme_slug,
|
113 |
'version' => $current_theme_version,
|
114 |
-
);
|
115 |
-
|
116 |
if (in_array( $current_theme_slug, array_keys( $this->supported_themes) )) {
|
117 |
// supported theme, check version
|
118 |
if ( version_compare( $current_theme_version, $this->supported_themes[$current_theme_slug], '>=' ) ):
|
119 |
// supported version
|
120 |
$this->status = 1;
|
121 |
return 1;
|
122 |
-
elseif ( isset($this->compatibility_themes[$current_theme_slug]) && (version_compare( $current_theme_version, $this->compatibility_themes[$current_theme_slug], '>=' ) ) &&
|
123 |
(version_compare($wp_version, '4.3.9999') >= 0) ):
|
124 |
// compatibility mode
|
125 |
$this->status = 4;
|
@@ -137,46 +137,54 @@ class Cryout_Theme_Settings {
|
|
137 |
// unsupported theme
|
138 |
$this->status = 3;
|
139 |
return 0;
|
140 |
-
};
|
141 |
-
|
142 |
} // supported_theme()
|
143 |
-
|
144 |
public function enqueue_script($hook) {
|
145 |
-
if (
|
146 |
wp_enqueue_script( 'cryout-theme-settings-code', plugins_url( 'code.js', __FILE__ ), NULL, $this->version );
|
|
|
147 |
} // enqueue_script()
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
}
|
154 |
-
|
155 |
-
// register plugin settings
|
156 |
-
public function register_settings() {
|
157 |
-
register_setting( 'cryout_theme_settings_settingsgroup', array( $this, 'settings' ) );
|
158 |
-
} // register_settings() */
|
159 |
-
|
160 |
// register settings page to dashboard menu
|
161 |
public function settings_menu() {
|
162 |
-
add_submenu_page('themes.php', $this->title, $this->title, 'manage_options', $this->slug, array( $this, 'settings_page' ) );
|
163 |
}
|
164 |
-
|
165 |
// add settings link on plugin page
|
166 |
-
public function settings_link($links) {
|
167 |
-
$settings_link = '<a href="themes.php?page=' . $this->slug . '">' . __( '
|
168 |
-
array_unshift($links, $settings_link);
|
169 |
-
return $links;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
170 |
}
|
171 |
-
|
172 |
public function settings_page() {
|
173 |
require_once( plugin_dir_path( __FILE__ ) . 'inc/settings.php' );
|
174 |
-
}
|
175 |
-
|
176 |
} // class Cryout_Theme_Settings
|
177 |
|
178 |
|
179 |
/* * * * get things going * * * */
|
180 |
if (is_admin()) $cryout_theme_settings = new Cryout_Theme_Settings;
|
181 |
|
182 |
-
// EOF
|
2 |
/*
|
3 |
Plugin Name: Cryout Serious Theme Settings
|
4 |
Plugin URI: https://www.cryoutcreations.eu/serious-theme-settings
|
5 |
+
Description: This plugin is designed to restore our theme's settings page functionality after the enforcement of the Customize-based theme settings. It is only compatible with and will only function when one of our themes is active: Nirvana, Parabola, Tempera or Mantra.
|
6 |
+
Version: 0.5.8
|
7 |
Author: Cryout Creations
|
8 |
Author URI: https://www.cryoutcreations.eu
|
9 |
License: GPLv3
|
11 |
*/
|
12 |
|
13 |
class Cryout_Theme_Settings {
|
14 |
+
public $version = "0.5.8";
|
15 |
public $settings = array();
|
16 |
+
|
17 |
private $status = 0; // 0 = inactive, 1 = active, 2 = good theme, wrong version, 3 = wrong theme, 4 = compatibility for wp4.4, 5 = theme requires update
|
18 |
+
|
19 |
private $supported_themes = array(
|
20 |
'nirvana' => '1.2',
|
21 |
'tempera' => '1.4',
|
33 |
private $slug = 'cryout-theme-settings';
|
34 |
private $title = '';
|
35 |
public $current_theme = array();
|
36 |
+
public $plugin_page = array();
|
37 |
public $renamed_theme = false;
|
38 |
+
|
39 |
public function __construct(){
|
40 |
+
add_action( 'init', array( $this, 'register' ) );
|
41 |
} // __construct()
|
42 |
|
43 |
public function register(){
|
44 |
+
|
45 |
$this->title = __( 'Cryout Serious Theme Settings', 'cryout-theme-settings' );
|
46 |
if ( $this->supported_theme() ):
|
47 |
+
|
48 |
switch ($this->status):
|
49 |
case 1: // restore theme settings
|
50 |
+
|
51 |
include_once( plugin_dir_path( __FILE__ ) . 'inc/' . strtolower($this->current_theme['slug']) . '.php' );
|
52 |
+
|
53 |
+
break;
|
54 |
+
case 4: // repair wrong headings
|
55 |
+
|
56 |
+
add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_script' ) );
|
57 |
+
|
58 |
break;
|
59 |
+
|
60 |
+
default:
|
61 |
break;
|
62 |
endswitch;
|
63 |
+
|
64 |
+
endif;
|
65 |
+
|
66 |
+
$cryout_theme_settings_slug = plugin_basename(__FILE__);
|
67 |
+
add_filter( 'plugin_action_links_'.$cryout_theme_settings_slug, array( $this, 'settings_link' ) );
|
68 |
+
add_filter( 'plugin_row_meta', array( $this, 'meta_links' ), 10, 2 );
|
|
|
|
|
69 |
add_action( 'admin_menu', array( $this, 'settings_menu' ) );
|
70 |
+
add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_style' ) );
|
71 |
+
|
72 |
} // register()
|
73 |
+
|
74 |
function supported_theme(){
|
75 |
global $wp_version;
|
76 |
+
|
77 |
$current_theme_slug = strtolower( wp_get_theme()->Template );
|
78 |
$current_theme_version = wp_get_theme($current_theme_slug)->Version;
|
79 |
+
|
80 |
if (!in_array( $current_theme_slug, array_keys( $this->supported_themes) )) {
|
81 |
// theme slug does not match supported themes
|
82 |
// perform additional checks for theme constants
|
83 |
+
|
84 |
if (defined('MANTRA_VERSION')) {
|
85 |
if ($current_theme_slug != 'mantra') $this->renamed_theme = true;
|
86 |
$current_theme_slug = 'mantra';
|
87 |
+
$current_theme_version = MANTRA_VERSION;
|
88 |
}
|
89 |
if (defined('PARABOLA_VERSION')) {
|
90 |
if ($current_theme_slug != 'parabola') $this->renamed_theme = true;
|
91 |
$current_theme_slug = 'parabola';
|
92 |
+
$current_theme_version = PARABOLA_VERSION;
|
93 |
}
|
94 |
if (defined('TEMPERA_VERSION')) {
|
95 |
if ($current_theme_slug != 'tempera') $this->renamed_theme = true;
|
96 |
$current_theme_slug = 'tempera';
|
97 |
+
$current_theme_version = TEMPERA_VERSION;
|
98 |
}
|
99 |
if (defined('NIRVANA_VERSION')) {
|
100 |
if ($current_theme_slug != 'nirvana') $this->renamed_theme = true;
|
101 |
$current_theme_slug = 'nirvana';
|
102 |
+
$current_theme_version = NIRVANA_VERSION;
|
103 |
}
|
104 |
if (defined('_CRYOUT_THEME_NAME')) {
|
105 |
if ($current_theme_slug != _CRYOUT_THEME_NAME) $this->renamed_theme = true;
|
107 |
if (defined('_CRYOUT_THEME_VERSION')) $current_theme_version = _CRYOUT_THEME_VERSION;
|
108 |
}
|
109 |
} // end additional checks
|
110 |
+
|
111 |
$this->current_theme = array(
|
112 |
+
'slug' => $current_theme_slug,
|
113 |
'version' => $current_theme_version,
|
114 |
+
);
|
115 |
+
|
116 |
if (in_array( $current_theme_slug, array_keys( $this->supported_themes) )) {
|
117 |
// supported theme, check version
|
118 |
if ( version_compare( $current_theme_version, $this->supported_themes[$current_theme_slug], '>=' ) ):
|
119 |
// supported version
|
120 |
$this->status = 1;
|
121 |
return 1;
|
122 |
+
elseif ( isset($this->compatibility_themes[$current_theme_slug]) && (version_compare( $current_theme_version, $this->compatibility_themes[$current_theme_slug], '>=' ) ) &&
|
123 |
(version_compare($wp_version, '4.3.9999') >= 0) ):
|
124 |
// compatibility mode
|
125 |
$this->status = 4;
|
137 |
// unsupported theme
|
138 |
$this->status = 3;
|
139 |
return 0;
|
140 |
+
};
|
141 |
+
|
142 |
} // supported_theme()
|
143 |
+
|
144 |
public function enqueue_script($hook) {
|
145 |
+
if ( $hook == $this->current_theme['slug'] . '-page' ) {
|
146 |
wp_enqueue_script( 'cryout-theme-settings-code', plugins_url( 'code.js', __FILE__ ), NULL, $this->version );
|
147 |
+
}
|
148 |
} // enqueue_script()
|
149 |
+
|
150 |
+
public function enqueue_style($hook) {
|
151 |
+
if ( $hook == $this->plugin_page ) {
|
152 |
+
wp_enqueue_style( 'cryout-theme-settings-style', plugins_url( 'style.css', __FILE__ ), NULL, $this->version );
|
153 |
+
}
|
154 |
+
}
|
155 |
+
|
|
|
|
|
|
|
|
|
|
|
156 |
// register settings page to dashboard menu
|
157 |
public function settings_menu() {
|
158 |
+
$this->plugin_page = add_submenu_page('themes.php', $this->title, $this->title, 'manage_options', $this->slug, array( $this, 'settings_page' ) );
|
159 |
}
|
160 |
+
|
161 |
// add settings link on plugin page
|
162 |
+
public function settings_link($links) {
|
163 |
+
$settings_link = '<a href="themes.php?page=' . $this->slug . '">' . __( 'About Plugin', 'cryout-theme-settings' ) . '</a>';
|
164 |
+
array_unshift($links, $settings_link);
|
165 |
+
return $links;
|
166 |
+
}
|
167 |
+
|
168 |
+
// add plugin meta links
|
169 |
+
public function meta_links( $links, $file ) {
|
170 |
+
// Check plugin
|
171 |
+
if ( $file === plugin_basename( __FILE__ ) ) {
|
172 |
+
unset( $links[2] );
|
173 |
+
$links[] = '<a href="http://www.cryoutcreations.eu/cryout-theme-settings/" target="_blank">' . __( 'Plugin homepage', 'cryout-serious-slider' ) . '</a>';
|
174 |
+
$links[] = '<a href="https://www.cryoutcreations.eu/forums/f/wordpress/plugins/serious-settings" target="_blank">' . __( 'Support forum', 'cryout-serious-slider' ) . '</a>';
|
175 |
+
$links[] = '<a href="http://wordpress.org/plugins/cryout-theme-settings/#developers" target="_blank">' . __( 'Changelog', 'cryout-serious-slider' ) . '</a>';
|
176 |
+
}
|
177 |
+
return $links;
|
178 |
}
|
179 |
+
|
180 |
public function settings_page() {
|
181 |
require_once( plugin_dir_path( __FILE__ ) . 'inc/settings.php' );
|
182 |
+
}
|
183 |
+
|
184 |
} // class Cryout_Theme_Settings
|
185 |
|
186 |
|
187 |
/* * * * get things going * * * */
|
188 |
if (is_admin()) $cryout_theme_settings = new Cryout_Theme_Settings;
|
189 |
|
190 |
+
// EOF
|
inc/extra.php
ADDED
@@ -0,0 +1,182 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<div id="latest-themes" class="postbox">
|
2 |
+
<h3 class="hndle"> Our latest free themes </h3>
|
3 |
+
<div id="slider">
|
4 |
+
<a href="#" class="control_next">></a>
|
5 |
+
<a href="#" class="control_prev"><</a>
|
6 |
+
<ul>
|
7 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/anima" target="_blank"><span>Anima WordPress Theme</span><img src="<?php echo $url ?>/anima.jpg"></a></li>
|
8 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/septera" target="_blank"><span>Septera WordPress Theme</span><img src="<?php echo $url ?>/septera.jpg"></a></li>
|
9 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/verbosa" target="_blank"><span>Verbosa WordPress Theme</span><img src="<?php echo $url ?>/verbosa.jpg"></a></li>
|
10 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/fluida" target="_blank"><span>Fluida WordPress Theme</span><img src="<?php echo $url ?>/fluida.jpg"></a></li>
|
11 |
+
</ul>
|
12 |
+
</div>
|
13 |
+
</div>
|
14 |
+
|
15 |
+
<div id="priority-support" class="postbox priority-support">
|
16 |
+
<div title="Click to toggle" class="handlediv"><br /></div>
|
17 |
+
<h3 class="hndle"> Need help? </h3>
|
18 |
+
<div class="inside">
|
19 |
+
<a href="https://www.cryoutcreations.eu/pricing" target="_blank"><img src="<?php echo $url ?>/priority-support.jpg' ?>"></a>
|
20 |
+
</div><!--inside-->
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<style type="text/css">
|
24 |
+
.priority-support.postbox .inside {
|
25 |
+
margin: 0;
|
26 |
+
padding: 5px 0 0 0;
|
27 |
+
}
|
28 |
+
|
29 |
+
#slider {
|
30 |
+
position: relative;
|
31 |
+
overflow: hidden;
|
32 |
+
margin: 5px auto 0;
|
33 |
+
}
|
34 |
+
|
35 |
+
#slider ul {
|
36 |
+
position: relative;
|
37 |
+
margin: 0;
|
38 |
+
padding: 0;
|
39 |
+
height: 375px;
|
40 |
+
list-style: none;
|
41 |
+
overflow: hidden;
|
42 |
+
}
|
43 |
+
|
44 |
+
#slider ul li {
|
45 |
+
position: relative;
|
46 |
+
display: block;
|
47 |
+
float: left;
|
48 |
+
margin: 0;
|
49 |
+
padding: 0;
|
50 |
+
width: 500px;
|
51 |
+
height: 375px;
|
52 |
+
background: #ccc;
|
53 |
+
text-align: center;
|
54 |
+
}
|
55 |
+
|
56 |
+
#slider a span {
|
57 |
+
display: inline-block;
|
58 |
+
position: absolute;
|
59 |
+
left: 0;
|
60 |
+
right: 0;
|
61 |
+
bottom: 0;
|
62 |
+
margin: auto;
|
63 |
+
opacity: 0;
|
64 |
+
background: rgba(0,0,0,.5);
|
65 |
+
max-width: 200px;
|
66 |
+
height: 40px;
|
67 |
+
line-height: 40px;
|
68 |
+
font-size: 1.2em;
|
69 |
+
color: #FFF;
|
70 |
+
-webkit-transition: .3s ease-out all;
|
71 |
+
transition: .3s ease-out all;
|
72 |
+
}
|
73 |
+
|
74 |
+
#slider:hover a span {
|
75 |
+
opacity: 1;
|
76 |
+
}
|
77 |
+
|
78 |
+
a.control_prev,
|
79 |
+
a.control_next {
|
80 |
+
position: absolute;
|
81 |
+
top: 50%;
|
82 |
+
-webkit-transform:translateY(-50%);
|
83 |
+
transform:translateY(-50%);
|
84 |
+
z-index: 999;
|
85 |
+
display: block;
|
86 |
+
padding: 4% 3%;
|
87 |
+
width: auto;
|
88 |
+
height: auto;
|
89 |
+
background: #2a2a2a;
|
90 |
+
color: #fff;
|
91 |
+
text-decoration: none;
|
92 |
+
font-weight: 600;
|
93 |
+
font-size: 18px;
|
94 |
+
opacity: 0.3;
|
95 |
+
cursor: pointer;
|
96 |
+
}
|
97 |
+
|
98 |
+
a.control_prev:hover,
|
99 |
+
a.control_next:hover {
|
100 |
+
opacity: .8;
|
101 |
+
-webkit-transition: all 0.2s ease;
|
102 |
+
transition: all 0.2s ease;
|
103 |
+
}
|
104 |
+
|
105 |
+
a.control_prev {
|
106 |
+
border-radius: 0 2px 2px 0;
|
107 |
+
}
|
108 |
+
|
109 |
+
a.control_next {
|
110 |
+
right: 0;
|
111 |
+
border-radius: 2px 0 0 2px;
|
112 |
+
}
|
113 |
+
|
114 |
+
.no-js #slider img {
|
115 |
+
width: 100%;
|
116 |
+
}
|
117 |
+
|
118 |
+
.no-js #slider ul li {
|
119 |
+
width: 50%;
|
120 |
+
height: 50%;
|
121 |
+
}
|
122 |
+
|
123 |
+
.no-js .control_next,
|
124 |
+
.no-js .control_prev {
|
125 |
+
display: none;
|
126 |
+
}
|
127 |
+
|
128 |
+
.no-js #slider ul li:hover a span {
|
129 |
+
background: rgba(0,0,0,.8);
|
130 |
+
}
|
131 |
+
</style>
|
132 |
+
|
133 |
+
<script type="text/javascript">
|
134 |
+
jQuery(document).ready(function ($) {
|
135 |
+
interval = 25000;
|
136 |
+
// autoplay
|
137 |
+
setInterval(function () {
|
138 |
+
moveRight();
|
139 |
+
}, interval);
|
140 |
+
|
141 |
+
|
142 |
+
var slideCount = $('#slider ul li').length;
|
143 |
+
var slideWidth = $('#slider ul li').width();
|
144 |
+
var slideHeight = $('#slider ul li').height();
|
145 |
+
var sliderUlWidth = slideCount * slideWidth;
|
146 |
+
|
147 |
+
$('#slider').css({ width: slideWidth, height: slideHeight });
|
148 |
+
|
149 |
+
$('#slider ul').css({ width: sliderUlWidth, marginLeft: - slideWidth });
|
150 |
+
|
151 |
+
$('#slider ul li:last-child').prependTo('#slider ul');
|
152 |
+
|
153 |
+
function moveLeft() {
|
154 |
+
$('#slider ul').animate({
|
155 |
+
left: + slideWidth
|
156 |
+
}, 500, function () {
|
157 |
+
$('#slider ul li:last-child').prependTo('#slider ul');
|
158 |
+
$('#slider ul').css('left', '');
|
159 |
+
});
|
160 |
+
};
|
161 |
+
|
162 |
+
function moveRight() {
|
163 |
+
$('#slider ul').animate({
|
164 |
+
left: - slideWidth
|
165 |
+
}, 500, function () {
|
166 |
+
$('#slider ul li:first-child').appendTo('#slider ul');
|
167 |
+
$('#slider ul').css('left', '');
|
168 |
+
});
|
169 |
+
};
|
170 |
+
|
171 |
+
$('a.control_prev').click(function ( e ) {
|
172 |
+
e.preventDefault();
|
173 |
+
moveLeft();
|
174 |
+
});
|
175 |
+
|
176 |
+
$('a.control_next').click(function ( e ) {
|
177 |
+
e.preventDefault();
|
178 |
+
moveRight();
|
179 |
+
});
|
180 |
+
|
181 |
+
});
|
182 |
+
</script>
|
inc/nirvana.php
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
<?php
|
2 |
if (function_exists('nirvana_init_fn')):
|
3 |
add_action('admin_init', 'nirvana_init_fn');
|
|
|
4 |
endif;
|
5 |
|
6 |
function nirvana_theme_settings_restore($class='') {
|
7 |
-
global $wp_version;
|
8 |
global $cryout_theme_settings;
|
9 |
?>
|
10 |
<form name="nirvana_form" id="nirvana_form" action="options.php" method="post" enctype="multipart/form-data">
|
@@ -21,3 +21,7 @@ function nirvana_theme_settings_restore($class='') {
|
|
21 |
<?php
|
22 |
} // nirvana_theme_settings_buttons()
|
23 |
|
|
|
|
|
|
|
|
1 |
<?php
|
2 |
if (function_exists('nirvana_init_fn')):
|
3 |
add_action('admin_init', 'nirvana_init_fn');
|
4 |
+
add_action('nirvana_before_righty', 'nirvana_extra');
|
5 |
endif;
|
6 |
|
7 |
function nirvana_theme_settings_restore($class='') {
|
|
|
8 |
global $cryout_theme_settings;
|
9 |
?>
|
10 |
<form name="nirvana_form" id="nirvana_form" action="options.php" method="post" enctype="multipart/form-data">
|
21 |
<?php
|
22 |
} // nirvana_theme_settings_buttons()
|
23 |
|
24 |
+
function nirvana_extra() {
|
25 |
+
$url = plugin_dir_url( dirname(__FILE__) ) . '/media';
|
26 |
+
include_once( plugin_dir_path( __FILE__ ) . 'extra.php' );
|
27 |
+
} // nirvana_extra()
|
inc/parabola.php
CHANGED
@@ -1,6 +1,7 @@
|
|
1 |
<?php
|
2 |
if (function_exists('parabola_init_fn')):
|
3 |
add_action('admin_init', 'parabola_init_fn');
|
|
|
4 |
endif;
|
5 |
|
6 |
function parabola_theme_settings_restore($class='') {
|
@@ -19,3 +20,8 @@ function parabola_theme_settings_restore($class='') {
|
|
19 |
</form>
|
20 |
<?php
|
21 |
} // parabola_theme_settings_buttons()
|
|
|
|
|
|
|
|
|
|
1 |
<?php
|
2 |
if (function_exists('parabola_init_fn')):
|
3 |
add_action('admin_init', 'parabola_init_fn');
|
4 |
+
add_action('parabola_before_righty', 'parabola_extra');
|
5 |
endif;
|
6 |
|
7 |
function parabola_theme_settings_restore($class='') {
|
20 |
</form>
|
21 |
<?php
|
22 |
} // parabola_theme_settings_buttons()
|
23 |
+
|
24 |
+
function parabola_extra() {
|
25 |
+
$url = plugin_dir_url( dirname(__FILE__) ) . '/media';
|
26 |
+
include_once( plugin_dir_path( __FILE__ ) . 'extra.php' );
|
27 |
+
} // parabola_extra()
|
inc/settings.php
CHANGED
@@ -1,44 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
<div class="wrap">
|
2 |
<h2><?php _e('Cryout Serious Theme Settings Status', 'cryout-theme-settings') ?></h2>
|
3 |
-
|
4 |
<?php if ($this->status == 1): ?>
|
5 |
-
<div class="updated"><p>Current active (or parent) theme is: <strong><?php echo
|
6 |
The plugin is <strong style="color: #008000;">active</strong>.<br>
|
7 |
<br>
|
8 |
-
|
9 |
</p></div>
|
10 |
<?php elseif ($this->status == 4): ?>
|
11 |
-
<div class="updated"><p>Current active (or parent) theme is: <strong><?php echo
|
12 |
The plugin is <strong style="color: #008000;">active</strong> in compatibility mode.<br>
|
13 |
<br>
|
14 |
-
|
15 |
</p></div>
|
16 |
<?php else: ?>
|
17 |
<div class="error"><p>
|
18 |
<?php
|
19 |
switch ($this->status):
|
20 |
-
case 5:
|
21 |
// theme requires update ?>
|
22 |
-
Current active (or parent) theme is: <strong><?php echo
|
23 |
This plugin cannot work with this version of the theme. Please update the theme first. <br>
|
24 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
25 |
break;
|
26 |
-
case 3:
|
27 |
// unsupported theme ?>
|
28 |
-
Current active (or parent) theme is: <strong><?php echo
|
29 |
This plugin is designed to work only with the supported themes. <br>
|
30 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
31 |
break;
|
32 |
case 2:
|
33 |
// unsupported version ?>
|
34 |
-
Current active (or parent) theme is: <strong><?php echo
|
35 |
-
You are running <em><?php echo
|
36 |
-
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
37 |
break;
|
38 |
case 0:
|
39 |
-
default:
|
40 |
// inactive/undefined ?>
|
41 |
-
Current active (or parent) theme is: <strong><?php echo
|
42 |
This plugin is designed to work only with the supported themes. <br>
|
43 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
44 |
break; ?>
|
@@ -51,39 +58,51 @@
|
|
51 |
If you need to customize the theme code, we strongly recommend creating a <a href="http://www.cryoutcreations.eu/wordpress-themes/wordpress-tutorials/wordpress-child-themes" target="_blank">child theme</a>.</p>
|
52 |
</div>
|
53 |
<?php endif; ?>
|
54 |
-
|
55 |
<div id="poststuff">
|
56 |
<div id="post-body" class="metabox-holder columns-2">
|
57 |
-
|
58 |
<div id="post-body-content">
|
59 |
-
|
60 |
<div class="postbox">
|
61 |
|
62 |
<div class="handlediv"><br></div>
|
63 |
<h3 class="hndle"><span>About</span></h3>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
|
|
|
|
|
65 |
<div class="inside">
|
66 |
-
|
67 |
-
|
68 |
-
<
|
69 |
-
<li><a href="
|
70 |
-
<li><a href="
|
71 |
-
|
72 |
-
</ul>
|
73 |
-
To restore their theme settings pages which we had to remove due to the Customize-based settings enforcement.<br>
|
74 |
-
</p>
|
75 |
-
<hr>
|
76 |
-
<p>
|
77 |
-
Additionally, the plugin will restore the settings page to working condition on WordPress 4.4-RC1 and newer with:
|
78 |
-
<ul><li><u>Tempera</u> versions 0.9 - 1.3.3</li>
|
79 |
-
<li><u>Parabola</u> versions 0.9 - 1.5.1</li>
|
80 |
-
<li><a href="http://wordpress.org/themes/mantra" target="_blank">Mantra</a> versions 2.0 - 2.4.1.1</li>
|
81 |
-
</ul>
|
82 |
-
</p>
|
83 |
-
<p>If you are using a different theme or a theme version not listed here this plugin will not activate.</p>
|
84 |
</div>
|
85 |
</div>
|
86 |
-
|
87 |
</div> <!-- post-body-content-->
|
88 |
|
89 |
<div class="postbox-container" id="postbox-container-1">
|
@@ -112,7 +131,7 @@
|
|
112 |
</h3><div class="inside">
|
113 |
<div style="text-align: center; margin: auto">
|
114 |
For support questions,<br>
|
115 |
-
please use <a target="_blank" href="http://www.cryoutcreations.eu/forum">our forum</a>.
|
116 |
</div>
|
117 |
</div>
|
118 |
</div>
|
1 |
+
<?php
|
2 |
+
$theme_page_url = admin_url( 'themes.php?page=' . $this->current_theme['slug'] . '-page' );
|
3 |
+
$theme_slug = $this->current_theme['slug'];
|
4 |
+
$theme_name = ucwords($this->current_theme['slug']);
|
5 |
+
$url = plugin_dir_url( dirname(__FILE__) ) . 'media';
|
6 |
+
?>
|
7 |
+
|
8 |
<div class="wrap">
|
9 |
<h2><?php _e('Cryout Serious Theme Settings Status', 'cryout-theme-settings') ?></h2>
|
10 |
+
|
11 |
<?php if ($this->status == 1): ?>
|
12 |
+
<div class="updated"><p>Current active (or parent) theme is: <strong><?php echo $theme_name; ?></strong>.
|
13 |
The plugin is <strong style="color: #008000;">active</strong>.<br>
|
14 |
<br>
|
15 |
+
Go <a href="<?php echo $theme_page_url ?>"><strong>configure <?php echo $theme_name ?></strong></a>.
|
16 |
</p></div>
|
17 |
<?php elseif ($this->status == 4): ?>
|
18 |
+
<div class="updated"><p>Current active (or parent) theme is: <strong><?php echo $theme_name; ?></strong> and you are running WordPress 4.4 or newer.
|
19 |
The plugin is <strong style="color: #008000;">active</strong> in compatibility mode.<br>
|
20 |
<br>
|
21 |
+
Go <a href="<?php echo $theme_page_url ?>"><strong>configure <?php echo $theme_name ?></strong></a>.
|
22 |
</p></div>
|
23 |
<?php else: ?>
|
24 |
<div class="error"><p>
|
25 |
<?php
|
26 |
switch ($this->status):
|
27 |
+
case 5:
|
28 |
// theme requires update ?>
|
29 |
+
Current active (or parent) theme is: <strong><?php echo $theme_name; ?></strong>.<br>
|
30 |
This plugin cannot work with this version of the theme. Please update the theme first. <br>
|
31 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
32 |
break;
|
33 |
+
case 3:
|
34 |
// unsupported theme ?>
|
35 |
+
Current active (or parent) theme is: <strong><?php echo $theme_name; ?></strong>.<br>
|
36 |
This plugin is designed to work only with the supported themes. <br>
|
37 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
38 |
break;
|
39 |
case 2:
|
40 |
// unsupported version ?>
|
41 |
+
Current active (or parent) theme is: <strong><?php echo $theme_name ?></strong>, however the plugin is designed to work with version <b><?php echo $this->supported_themes[$this->current_theme['slug']] ?></b> or newer of <em><?php echo $theme_name ?></em>.<br>
|
42 |
+
You are running <em><?php echo $theme_name ?> version <?php echo $this->current_theme['version'] ?></em> which does not need this plugin.</br>
|
43 |
+
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
44 |
break;
|
45 |
case 0:
|
46 |
+
default:
|
47 |
// inactive/undefined ?>
|
48 |
+
Current active (or parent) theme is: <strong><?php echo $theme_name; ?></strong>.<br>
|
49 |
This plugin is designed to work only with the supported themes. <br>
|
50 |
The plugin is <strong style="color: #800000;">INACTIVE</strong>. <?php
|
51 |
break; ?>
|
58 |
If you need to customize the theme code, we strongly recommend creating a <a href="http://www.cryoutcreations.eu/wordpress-themes/wordpress-tutorials/wordpress-child-themes" target="_blank">child theme</a>.</p>
|
59 |
</div>
|
60 |
<?php endif; ?>
|
61 |
+
|
62 |
<div id="poststuff">
|
63 |
<div id="post-body" class="metabox-holder columns-2">
|
64 |
+
|
65 |
<div id="post-body-content">
|
66 |
+
|
67 |
<div class="postbox">
|
68 |
|
69 |
<div class="handlediv"><br></div>
|
70 |
<h3 class="hndle"><span>About</span></h3>
|
71 |
+
<div class="inside">
|
72 |
+
<?php if ($this->status != 4) { ?>
|
73 |
+
<p>This plugin is designed to inter-operate with our supported themes:</p>
|
74 |
+
<ul> <li><a href="http://wordpress.org/themes/mantra" target="_blank"><img src="<?php echo $url . '/mantra.jpg'; ?>" /><span>Mantra</span></a> version 2.5 and newer</li>
|
75 |
+
<li><a href="http://wordpress.org/themes/nirvana" target="_blank"><img src="<?php echo $url . '/nirvana.jpg'; ?>" /><span>Nirvana</span></a> version 1.2 and newer</li>
|
76 |
+
<li><a href="http://wordpress.org/themes/parabola" target="_blank"><img src="<?php echo $url . '/parabola.jpg'; ?>" /><span>Parabola</span></a> version 1.6 and newer</li>
|
77 |
+
<li><a href="http://wordpress.org/themes/tempera" target="_blank"><img src="<?php echo $url . '/tempera.jpg'; ?>" /><span>Tempera</span></a> version 1.4 and newer</li> </ul>
|
78 |
+
<p>To restore their theme settings pages which we had to remove due to the Customize-based settings enforcement.</p>
|
79 |
+
<p>If you are using a different theme or a theme version not listed here this plugin will not activate.</p>
|
80 |
+
<?php } else { ?>
|
81 |
+
<p>
|
82 |
+
This plugin will restore the settings page to working condition on WordPress 4.4-RC1 and newer with:
|
83 |
+
<ul> <li><a href="http://wordpress.org/themes/mantra" target="_blank">Mantra</a> versions 2.0 - 2.4.1.1</li>
|
84 |
+
<li><a href="http://wordpress.org/themes/parabola" target="_blank">Parabola</a> versions 0.9 - 1.5.1</li>
|
85 |
+
<li><a href="http://wordpress.org/themes/tempera" target="_blank">Tempera</a> versions 0.9 - 1.3.3</li> </ul>
|
86 |
+
</p>
|
87 |
+
<p>If you are using a different theme or a theme version not listed here this plugin will not activate.</p>
|
88 |
+
<?php } ?>
|
89 |
+
</div>
|
90 |
+
</div>
|
91 |
+
|
92 |
+
<div class="postbox">
|
93 |
|
94 |
+
<div class="handlediv"><br></div>
|
95 |
+
<h3 class="hndle"><span>Our Latest Themes</span></h3>
|
96 |
<div class="inside">
|
97 |
+
|
98 |
+
<ul> <li><a href="https://www.cryoutcreations.eu/wordpress-themes/anima" target="_blank"><img src="<?php echo $url . '/anima.jpg'; ?>" /><span>Anima</span></a></li>
|
99 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/septera" target="_blank"><img src="<?php echo $url . '/septera.jpg'; ?>" /><span>Septera</span></a></li>
|
100 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/verbosa" target="_blank"><img src="<?php echo $url . '/verbosa.jpg'; ?>" /><span>Verbosa</span></a></li>
|
101 |
+
<li><a href="https://www.cryoutcreations.eu/wordpress-themes/fluida" target="_blank"><img src="<?php echo $url . '/fluida.jpg'; ?>" /><span>Fluida</span></a></li> </ul>
|
102 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
103 |
</div>
|
104 |
</div>
|
105 |
+
|
106 |
</div> <!-- post-body-content-->
|
107 |
|
108 |
<div class="postbox-container" id="postbox-container-1">
|
131 |
</h3><div class="inside">
|
132 |
<div style="text-align: center; margin: auto">
|
133 |
For support questions,<br>
|
134 |
+
please use <a target="_blank" href="http://www.cryoutcreations.eu/forum">our forum</a>.
|
135 |
</div>
|
136 |
</div>
|
137 |
</div>
|
inc/tempera.php
CHANGED
@@ -1,6 +1,7 @@
|
|
1 |
<?php
|
2 |
if (function_exists('tempera_init_fn')):
|
3 |
add_action('admin_init', 'tempera_init_fn');
|
|
|
4 |
endif;
|
5 |
|
6 |
function tempera_theme_settings_restore($class='') {
|
@@ -19,3 +20,8 @@ function tempera_theme_settings_restore($class='') {
|
|
19 |
</form>
|
20 |
<?php
|
21 |
} // tempera_theme_settings_buttons()
|
|
|
|
|
|
|
|
|
|
1 |
<?php
|
2 |
if (function_exists('tempera_init_fn')):
|
3 |
add_action('admin_init', 'tempera_init_fn');
|
4 |
+
add_action('tempera_before_righty', 'tempera_extra');
|
5 |
endif;
|
6 |
|
7 |
function tempera_theme_settings_restore($class='') {
|
20 |
</form>
|
21 |
<?php
|
22 |
} // tempera_theme_settings_buttons()
|
23 |
+
|
24 |
+
function tempera_extra() {
|
25 |
+
$url = plugin_dir_url( dirname(__FILE__) ) . '/media';
|
26 |
+
include_once( plugin_dir_path( __FILE__ ) . 'extra.php' );
|
27 |
+
} // tempera_extra()
|
media/anima.jpg
ADDED
Binary file
|
media/fluida.jpg
ADDED
Binary file
|
media/mantra.jpg
ADDED
Binary file
|
media/nirvana.jpg
ADDED
Binary file
|
media/parabola.jpg
ADDED
Binary file
|
media/priority-support.jpg
ADDED
Binary file
|
media/septera.jpg
ADDED
Binary file
|
media/tempera.jpg
ADDED
Binary file
|
media/verbosa.jpg
ADDED
Binary file
|
readme.txt
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
=== Plugin Name ===
|
2 |
-
Contributors: Cryout Creations
|
3 |
Donate link: https://www.cryoutcreations.eu/donate/
|
4 |
Tags: theme, admin
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 4.8.0
|
7 |
-
Stable tag: 0.5.
|
8 |
License: GPLv3
|
9 |
License URI: http://www.gnu.org/licenses/gpl.html
|
10 |
|
@@ -50,6 +50,11 @@ You do not need this plugin if you use do not use any of the listed themes.
|
|
50 |
|
51 |
== Changelog ==
|
52 |
|
|
|
|
|
|
|
|
|
|
|
53 |
= 0.5.7 =
|
54 |
* Fixed incorrect status for Nirvana versions before 1.2
|
55 |
|
1 |
=== Plugin Name ===
|
2 |
+
Contributors: Cryout Creations
|
3 |
Donate link: https://www.cryoutcreations.eu/donate/
|
4 |
Tags: theme, admin
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 4.8.0
|
7 |
+
Stable tag: 0.5.8
|
8 |
License: GPLv3
|
9 |
License URI: http://www.gnu.org/licenses/gpl.html
|
10 |
|
50 |
|
51 |
== Changelog ==
|
52 |
|
53 |
+
= 0.5.8 =
|
54 |
+
* Added meta links
|
55 |
+
* Updated plugin's about page
|
56 |
+
* Added 'featured themes' and 'priority support' panels
|
57 |
+
|
58 |
= 0.5.7 =
|
59 |
* Fixed incorrect status for Nirvana versions before 1.2
|
60 |
|
style.css
ADDED
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/* About page styling */
|
2 |
+
|
3 |
+
#post-body-content ul {
|
4 |
+
display: inline-block;
|
5 |
+
margin-bottom: 2em;
|
6 |
+
}
|
7 |
+
|
8 |
+
#post-body-content ul li {
|
9 |
+
display: inline-block;
|
10 |
+
float: left;
|
11 |
+
width: 25%;
|
12 |
+
text-align: center;
|
13 |
+
}
|
14 |
+
|
15 |
+
#post-body-content ul li img {
|
16 |
+
width: 90%;
|
17 |
+
}
|
18 |
+
|
19 |
+
#post-body-content ul li span {
|
20 |
+
font-weight: bold;
|
21 |
+
}
|
22 |
+
|
23 |
+
#post-body-content ul li img {
|
24 |
+
border: 3px solid #DDD;
|
25 |
+
padding: 3px;
|
26 |
+
width: 90%;
|
27 |
+
-webkit-transition: .2s ease-out all;
|
28 |
+
transition: .2s ease-out all;
|
29 |
+
}
|
30 |
+
|
31 |
+
#post-body-content ul li:hover img {
|
32 |
+
background-color: #DDD;
|
33 |
+
}
|