PluginProbe
BlockSpare – Gutenberg Blocks for News, Magazine, Blog & Business Websites / trunk
BlockSpare – Gutenberg Blocks for News, Magazine, Blog & Business Websites vtrunk
4.1.0 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 1.1.0 1.1.1 1.1.2 1.2.0 1.2.1 1.2.2 1.2.3 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 2.1.2 2.5.0 2.5.3 2.6.1 All 38 releases
← All changes | admin/index.php +246 -231 2.5.0trunk View file →
@@ -1,5 +1,6 @@
1 1 <?php
2 +
2 3 /**
3 4 * Welcome screen.
4 5 */
5 6
@@ -4,28 +5,66 @@
4 5 */
5 6
6 7 // Exit if accessed directly.
7 8 if (!defined('ABSPATH')) {
8 - exit;
9 + exit;
9 10 }
10 11
11 12 if (!class_exists('Blockspare_Admin_Dashboard')) {
12 - class Blockspare_Admin_Dashboard
13 + class Blockspare_Admin_Dashboard
14 + {
15 + public function __construct()
13 16 {
14 - function __construct()
15 - {
16 - add_action('admin_menu', array($this, 'add_dashboard_page'));
17 + add_action('admin_menu', array($this, 'add_dashboard_page'));
17 18
18 - add_action('admin_enqueue_scripts', array($this, 'enqueue_dashboard_script'));
19 + add_action('admin_enqueue_scripts', array($this, 'enqueue_dashboard_script'));
19 20
20 - add_action('admin_init', array($this, 'redirect_to_blockspare_page'));
21 - }
21 + add_action('admin_init', array($this, 'redirect_to_blockspare_page'));
22 22
23 - public function add_dashboard_page()
24 - {
23 + //add_action('init', array($this, 'blockspare_load_api_files'));
25 24
26 - // @see images/blockspare-icon.svg
27 - $svg = <<< SVG
25 + add_filter('plugin_row_meta', [$this, 'plugin_row_meta'], 10, 2);
26 +
27 + add_filter('plugin_action_links_' . BLOCKSPARE_PLUGIN_BASE, [$this, 'plugin_action_links']);
28 +
29 + // include_once(BLOCKSPARE_PLUGIN_DIR . 'admin/notice-setup.php');
30 + // include_once(BLOCKSPARE_PLUGIN_DIR . 'admin/notice-theme.php');
31 + // include_once(BLOCKSPARE_PLUGIN_DIR . 'admin/notice-review.php');
32 + // include_once BLOCKSPARE_PLUGIN_DIR . 'admin/notice-upgrade.php';
33 + include_once(BLOCKSPARE_PLUGIN_DIR . 'admin/class-enable-disable-blocks.php');
34 + }
35 +
36 + public function plugin_action_links($links)
37 + {
38 + $settings_link = sprintf('<a href="%1$s">%2$s</a>', admin_url('admin.php?page=blockspare'), esc_html__('Get Started', 'blockspare'));
39 +
40 + array_unshift($links, $settings_link);
41 +
42 + $links['bspro'] = sprintf('<a href="%1$s" target="_blank" class="blockspare-pro-link">%2$s</a>', 'https://www.blockspare.com/', esc_html__('Upgrade', 'blockspare'));
43 +
44 + return $links;
45 + }
46 + public function plugin_row_meta($plugin_meta, $plugin_file)
47 + {
48 + if (BLOCKSPARE_PLUGIN_BASE === $plugin_file) {
49 + $row_meta = [
50 + 'starter' => '<a href="https://www.blockspare.com/starter-templates/" aria-label="' . esc_attr(esc_html__('View Blockspare Starter Templates', 'blockspare')) . '" target="_blank">' . esc_html__('Demos', 'blockspare') . '</a>',
51 + 'docs' => '<a href="https://www.blockspare.com/docs/" aria-label="' . esc_attr(esc_html__('View Blockspare Documentation', 'blockspare')) . '" target="_blank">' . esc_html__('Docs', 'blockspare') . '</a>',
52 + 'video' => '<a href="https://www.youtube.com/@blockspare" aria-label="' . esc_attr(esc_html__('View Blockspare Video Tutorials', 'blockspare')) . '" target="_blank">' . esc_html__('Videos', 'blockspare') . '</a>',
53 + 'support' => '<a href="https://afthemes.com/supports/" aria-label="' . esc_attr(esc_html__('Need help for Blockspare?', 'blockspare')) . '" target="_blank">' . esc_html__('Need help?', 'blockspare') . '</a>',
54 + ];
55 +
56 + $plugin_meta = array_merge($plugin_meta, $row_meta);
57 + }
58 +
59 + return $plugin_meta;
60 + }
61 +
62 + public function add_dashboard_page()
63 + {
64 +
65 + // @see images/blockspare-icon.svg
66 + $svg = <<< SVG
28 67 <svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
29 68 viewBox="0 0 40 40" style="enable-background:new 0 0 40 40;" xml:space="preserve">
30 69 <g>
31 70 <g>
@@ -32,9 +71,9 @@
32 71 <path class="st0" d="M1.6,9.2v21.4l18.3-9.2L20.2,0L1.6,9.2z M16.9,19.8L4.9,26V10.9l12-6.1V19.8z"/>
33 72 <polygon id="XMLID_3_" class="st1" points="19.9,21.4 16.9,23 26,27.7 13.8,33.8 4.9,29 1.6,30.7 13.9,36.9 32.4,27.7 "/>
34 73 </g>
35 74 <g>
36 - <polygon id="XMLID_2_" class="st0" points="23,1.5 23,19.8 32.4,24.6 32.4,9.4 35.3,10.9 35.3,29 38.4,30.7 38.4,9.2 29.4,4.8
75 + <polygon id="XMLID_2_" class="st0" points="23,1.5 23,19.8 32.4,24.6 32.4,9.4 35.3,10.9 35.3,29 38.4,30.7 38.4,9.2 29.4,4.8
37 76 29.2,19.7 26,18.4 26,3.1 "/>
38 77 <polygon id="XMLID_1_" class="st1" points="17,38.4 19.9,40 38.4,30.7 35.3,29 "/>
39 78 </g>
40 79 </g>
@@ -40,252 +79,228 @@
40 79 </g>
41 80 </svg>
42 81 SVG;
43 82
44 - add_menu_page(
45 - __('Blockspare', 'blockspare'), // Page Title.
46 - __('Blockspare', 'blockspare'), // Menu Title.
47 - 'edit_posts', // Capability.
48 - 'blockspare', // Menu slug.
49 - array($this, 'blockspare_admin_dashboard'), // Action.
50 - 'data:image/svg+xml;base64,' . base64_encode($svg) // Blockspare icon.
51 - );
83 + add_menu_page(
84 + __('Blockspare', 'blockspare'), // Page Title.
85 + __('Blockspare', 'blockspare'), // Menu Title.
86 + 'edit_posts', // Capability.
87 + 'blockspare', // Menu slug.
88 + array($this, 'blockspare_admin_dashboard'), // Action.
89 + 'data:image/svg+xml;base64,' . base64_encode($svg), // Blockspare icon.
90 + 25
91 + );
52 92
53 - // Our getting started page.
54 - add_submenu_page(
55 - 'blockspare', // Parent slug.
56 - __( 'Getting Started', 'blockspare' ), // Page title.
57 - __( 'Getting Started', 'blockspare' ), // Menu title.
58 - 'manage_options', // Capability.
59 - 'blockspare', // Menu slug.
60 - array( $this, 'blockspare_admin_dashboard' ), // Callback function.
61 - 1 // Position
62 - );
63 - }
93 + add_submenu_page(
94 + 'blockspare', // Parent slug.
95 + __('Home Dashboard', 'blockspare'), // Page title.
96 + __('Home Dashboard', 'blockspare'), // Menu title.
97 + 'manage_options', // Capability.
98 + 'blockspare', // Menu slug.
99 + array($this, 'blockspare_admin_dashboard'), // Callback function.
100 + 1 // Position
101 + );
64 102
65 - public function enqueue_dashboard_script($hook)
66 - {
67 - }
103 + // Our getting started page.
104 + add_submenu_page(
105 + 'blockspare', // Parent slug.
106 + __('Starter Templates', 'blockspare'), // Page title.
107 + __('Starter Templates', 'blockspare'), // Menu title.
108 + 'manage_options', // Capability.
109 + 'bspare-starter-sites', // Menu slug.
110 + array($this, 'blockspare_admin_blocks'), // Callback function.
111 + 1 // Position
112 + );
68 113
69 - public function blockspare_admin_dashboard()
70 - {
71 - ?>
72 -<div class="wrap blockspare-wrap">
73 - <header class="blockspare-header">
74 - <img src="<?php echo esc_url(plugins_url('assets/blockspare-logo.png', __FILE__)) ?>"
75 - alt="<?php esc_attr_e('Blockspare', 'blockspare') ?>" />
114 + add_submenu_page(
115 + 'blockspare', // Parent slug.
116 + __('Gutenberg Blocks', 'blockspare'), // Page title.
117 + __('Gutenberg Blocks', 'blockspare'), // Menu title.
118 + 'manage_options', // Capability.
119 + 'bs-blocks', // Menu slug.
120 + array($this, 'blockspare_admin_explore_more_blocks'), // Callback function.
121 + 2 // Position
122 + );
76 123
77 - <h1><?php _e('Blockspare', 'blockspare') ?></h1>
78 - <h2><?php _e('Beautiful Page Building Blocks for WordPress', 'blockspare') ?></h2>
124 + add_submenu_page(
125 + 'blockspare', // Parent slug.
126 + __('Saved Templates', 'blockspare'), // Page title.
127 + __('Saved Templates', 'blockspare'), // Menu title.
128 + 'manage_options', // Capability.
129 + 'edit.php?post_type=bs_templates', // Menu slug.
79 130
80 - <div class="blockspare-separator">
81 - <svg class="blockspare-separator-double-wave" preserveAspectRatio="none" aria-hidden="true"
82 - xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1946 175">
83 - <path class="st0"
84 - d="M-.5 27.7v146.8h1946V10.7s-170.6 20.4-265 57.2c0 0-374.1 116.7-794.2 24.7 0 0-414.1-100.9-673.1-92-.1 0-102.9 5.2-213.7 27.1z">
85 - </path>
86 - <path class="st1"
87 - d="M1945.5 69.9s-425.5-100-888 20.5c0 0-342.6 63.3-611.4 43.8 0 0-224.9-40.3-446.6-84.4V174h1946V69.9z">
88 - </path>
89 - <path d="M-.5 88s425.5-100 888 20.5c0 0 342.6 63.3 611.4 43.8 0 0 224.9-20.2 446.6-64.3v87H-.5V88z">
90 - </path>
91 - </svg>
92 - </div>
93 - </header>
94 - <section class="blockspare-main-container">
95 - <article class="blockspare-intro blockspare-section">
131 + );
132 + add_submenu_page(
133 + 'blockspare', // Parent slug.
134 + __('Compare Free & Pro', 'blockspare'), // Page title.
135 + __('Compare Free & Pro', 'blockspare'), // Menu title.
136 + 'manage_options', // Capability.
137 + 'bs-free-pro', // Capability.
138 + array($this, 'blockspare_admin_free_vs_pro'),
139 + );
96 140
97 - <div class="blockspare-intro-col blockspare-intro-desc">
98 - <div class="blockspare-common-header-wrapper">
99 - <span class="blockspare-subtitle"><?php _e('Amazing Blocks', 'blockspare') ?></span>
100 - <h2><?php _e('Envision Amazing Layouts with Blockspare', 'blockspare') ?></h2>
101 - </div>
141 + add_submenu_page(
142 + 'blockspare',
143 + esc_html__('Documentation', 'blockspare'),
144 + esc_html__('Documentation', 'blockspare'),
145 + 'manage_options',
146 + esc_url('https://blockspare.com/docs/')
102 147
103 - <p><?php _e('Now you have Blockspare for your WordPress editor', 'blockspare') ?></p>
104 - <ol>
105 - <li>
106 - <?php _e('Create a new page', 'blockspare') ?>
107 - </li>
108 - <li>
109 - <?php _e('Click on the <span class="plus-btn-svg"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="#222"><path d="M10 1c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7zm1-11H9v3H6v2h3v3h2v-3h3V9h-3V6z"></path></svg></span> button to add a block', 'blockspare') ?>
110 - </li>
111 - <li>
112 - <?php _e('Expand Blockspare panel!', 'blockspare') ?>
113 - </li>
114 - <li>
115 - <?php _e('Select to add and customize a block!', 'blockspare') ?>
116 - </li>
117 - </ol>
148 + );
118 149
119 - <a href="<?php echo esc_url(admin_url('post-new.php?post_type=page&blockspare_show_intro=true')) ?>"
120 - class="blockspare-button"
121 - title="<?php esc_attr_e('Try it on New Page', 'blockspare') ?>"><?php _e('Try it on New Page', 'blockspare') ?></a>
122 - </p>
123 - </div>
124 - <div class="blockspare-intro-col blockspare-intro-img">
125 - <p><img src="<?php echo esc_url(plugins_url('assets/blockspare-adding-blocks.gif', __FILE__)) ?>"
126 - alt="<?php esc_attr_e('Adding Blockspare', 'blockspare') ?>" class="blockspare-gif" /></p>
127 - <p>
128 - </div>
129 - </article>
130 - </section>
131 - <section class="blockspare-body-container">
132 - <div class="blockspare-body">
150 + add_submenu_page(
151 + 'blockspare', // Parent slug.
152 + __('Change Log', 'blockspare'), // Page title.
153 + __('Change Log', 'blockspare'), // Menu title.
154 + 'manage_options', // Capability.
155 + 'bs-change-log', // Menu slug.
156 + array($this, 'blockspare_admin_change_log'), // Callback function.
133 157
134 - <article class="blockspare-section blockspare-block-intro">
158 + );
135 159
136 - <div class="blockspare-common-header-wrapper">
137 - <span class="blockspare-subtitle"><?php _e('Enhanced set of Blocks', 'blockspare') ?></span>
138 - <h3><?php _e('Start Creating Page using Enhanced set of Blocks in Minutes!', 'blockspare') ?></h3>
139 - </div>
160 + add_submenu_page(
161 + 'blockspare',
162 + esc_html__('Explore More', 'blockspare'),
163 + esc_html__('Explore More', 'blockspare'),
164 + 'manage_options',
165 + esc_url('https://blockspare.com/')
140 166
141 - <p><?php _e('We design an elegant series of WordPress blocks to help you create the website you always wanted with ease.', 'blockspare') ?>
142 - </p>
143 - <!-- We put all the block controls here. -->
144 - <div class="blockspare-available-blocks-wrapper">
145 - <?php
146 - $blockspare_blocks = blockspare_admin_blocks_list();
147 - if (isset($blockspare_blocks) && !empty($blockspare_blocks)):
148 - foreach ($blockspare_blocks as $block):
149 - $blocks_name = $block['name'];
150 - $icon_url = plugins_url("assets/" .$block['slug'] . "-image.png", __FILE__);
151 - $demo_url = 'https://blockspare.com/block/'.$block['slug'];
167 + );
168 + add_submenu_page(
169 + 'blockspare',
170 + esc_html__('Need a Website?', 'blockspare'),
171 + esc_html__('Need a Website?', 'blockspare'),
172 + 'manage_options',
173 + esc_url('https://afthemes.com/make-a-website/')
152 174
153 - ?>
154 - <a class="blockspare-explore-btn" href="<?php echo esc_url($demo_url) ?>" target="_blank">
155 - <div class="blockspare-available-blocks">
175 + );
176 + add_submenu_page(
177 + 'blockspare',
178 + esc_html__('Power Bundle', 'blockspare'),
179 + esc_html__('Power Bundle', 'blockspare'),
180 + 'manage_options',
181 + esc_url('https://afthemes.com/all-themes-plan/')
156 182
157 - <img src="<?php echo esc_attr($icon_url); ?>" alt="<?php echo esc_attr($blocks_name) ?>">
158 - <h4>
159 - <?php echo esc_attr($blocks_name) ?>
160 - </h4>
183 + );
161 184
185 +
186 + add_submenu_page(
187 + 'blockspare',
188 + esc_html__('Support', 'blockspare'),
189 + esc_html__('Support', 'blockspare'),
190 + 'manage_options',
191 + esc_url('https://afthemes.com/supports/')
162 192
193 + );
194 + }
163 195
164 - </div>
165 - </a>
166 - <?php
167 - endforeach;
168 - endif;
169 196
170 - ?>
171 - </div>
172 - <div class="blocksparea-all-blocks-button"><a href="https://blockspare.com/" class="blockspare-button"
173 - target="_blank"
174 - title="<?php esc_attr_e('Explore All Blocks', 'blockspare') ?>"><?php _e('Explore All Blocks', 'blockspare') ?></a>
175 - </div>
176 - </article>
177 - <aside class="blockspare-backward-compatibility-control-wrapper"></aside>
178 - <?php if (BLOCKSPARE_SHOW_PRO_NOTICES): ?>
179 - <aside class="blockspare-pro-control-wrapper"></aside>
180 - <?php endif; ?>
181 - </div>
182 - <div class="blockspare-side">
197 + public function enqueue_dashboard_script($hook)
198 + {
199 + wp_enqueue_style('blockspare-admin', BLOCKSPARE_PLUGIN_URL . 'admin/assets/css/style.css', '', '');
200 + wp_enqueue_script('blockspare_dashboard_js', BLOCKSPARE_PLUGIN_URL . 'dist/block_admin_dashboard.js', array('react', 'react-dom', 'wp-components', 'wp-element', 'wp-api-fetch', 'wp-polyfill'), '1.0');
201 + wp_enqueue_style('blockspare-admin-css', BLOCKSPARE_PLUGIN_URL . 'dist/dashboard_css.css');
202 + wp_enqueue_script('wp-api');
203 + $blockspare_dashboard_logo = BLOCKSPARE_PLUGIN_URL . 'admin/assets/images/blockspare-logo.png';
204 + global $blockspare_block_manager;
183 205
184 - <div class="blockspare-side-sticky">
185 - <?php
186 - $blockspare_pro = true;
187 - if ($blockspare_pro == false ) : ?>
188 - <aside class="blockspare-section blockspare-premium-section">
189 - <h3><?php _e('Blockspare Pro', 'blockspare') ?></h3>
190 - <p><?php _e('Want to use Blockspare to build an awesome site with more options and controls? Upgrade to Pro and get:', 'blockspare') ?>
191 - </p>
192 - <ul class="blockspare-premium-features">
193 - <li><?php _e('30+ Custom WordPress Blocks', 'blockspare') ?></li>
194 - <li><?php _e('110+ Pre-designed Blocks Layouts', 'blockspare') ?></li>
195 - <li><?php _e('Gradient Colors Effects', 'blockspare') ?></li>
196 - <li><?php _e('Additional Block Options', 'blockspare') ?></li>
197 - <li><?php _e('Rearrangeable Inner Blocks', 'blockspare') ?></li>
198 - <li><?php _e('Image Masking Colors Effects and Filters ', 'blockspare') ?></li>
199 - <li><?php _e('All Premium Effects', 'blockspare') ?></li>
200 - <li><?php _e('Customer Email Support', 'blockspare') ?></li>
201 - <li><?php _e('Regular Updates & Premium Support', 'blockspare') ?></li>
202 - </ul>
203 - </p>
204 - <p>
205 - <a href="https://blockspare.com/" class="blockspare-button"
206 - title="<?php esc_attr_e('Get Blockspare Pro', 'blockspare') ?>"><?php esc_attr_e('Get Blockspare Pro', 'blockspare') ?></a>
207 - </p>
206 + wp_localize_script(
207 + 'blockspare_dashboard_js',
208 + 'blockspare_dashboard',
209 + array(
208 210
209 - </aside>
210 - <?php endif; ?>
211 + 'logo' => $blockspare_dashboard_logo,
212 + "imagePath" => "https://raw.githubusercontent.com/afthemes/blockspare-demo-data/master/blocks/new/",
213 + "static_img" => BLOCKSPARE_PLUGIN_URL,
214 + 'newPageUrl' => admin_url('post-new.php?post_type=page&blockspare_create_block'),
215 + 'adminPath' => admin_url('post-new.php?post_type=page&blockspare_show_intro=true'),
216 + 'pluginVesion' => BLOCKSPARE_VERSION,
217 + 'exploreUrl' => admin_url('admin.php?page=bs-blocks'),
218 + 'adminUrl' => admin_url('admin.php?page=blockspare'),
219 + 'templateUrl' => admin_url('edit.php?post_type=bs_templates'),
220 + 'starterUrl' => admin_url('admin.php?page=bspare-starter-sites'),
221 + 'blockUrl' => admin_url('admin.php?page=bs-blocks'),
222 + 'freevspro' => admin_url('admin.php?page=bs-free-pro'),
223 + 'changelogUrl' => admin_url('admin.php?page=bs-change-log'),
224 + 'docsUrl' => 'https://blockspare.com/docs/',
225 + 'channel' => 'https://www.youtube.com/@blockspare/videos',
226 + 'devChnagelog' => 'https://wordpress.org/plugins/blockspare/#developers',
227 + 'changelog' => blockspare_get_latest_change_log(),
228 + 'blocks' => $blockspare_block_manager->get_all_blocks(),
229 + 'disabledBlocks' => $blockspare_block_manager->get_disabled_blocks(),
211 230
212 - <aside class="blockspare-section">
213 - <h3><?php _e('Knowledge Base', 'blockspare') ?></h3>
214 - <ul class="blockspare-list blockspare-knowledge-base">
215 - <li>
216 - <h4 class="blockspare-sub-headings">
217 - <a href="https://blockspare.com/docs/"><?php esc_html_e('Documentations', 'blockspare') ?>
218 - →</a>
219 - </h4>
220 - <p><?php esc_html_e('Do you have any difficulties regarding plugin setup and uses? Please visit Documentations page.', 'blockspare') ?>
221 - </p>
222 - </li>
223 - <li>
224 - <h4 class="blockspare-sub-headings">
225 - <a href="https://blockspare.com/block/"><?php esc_html_e('Demos', 'blockspare') ?> →</a>
226 - </h4>
227 - <p><?php esc_html_e('We have also designed and displayed multiple type of layouts with Blockspare. For more details please visit our site.', 'blockspare') ?>
228 - </p>
229 - </li>
230 - <li>
231 - <h4 class="blockspare-sub-headings">
232 - <a href="https://blockspare.com/support/"><?php esc_html_e('Support', 'blockspare') ?>
233 - →</a>
234 - </h4>
235 - <p><?php esc_html_e('You directly come upon to our support guys with your valuable queries.', 'blockspare') ?>
236 - </p>
237 - </li>
238 - <li>
239 - <h4 class="blockspare-sub-headings">
240 - <a href="https://wordpress.org/plugins/blockspare/"><?php esc_html_e('WordPress Support Forum', 'blockspare') ?>
241 - →</a>
242 - </h4>
243 - <p><?php esc_html_e('You can also go to our .org forum for any kind of support enquiries.', 'blockspare') ?>
244 - </p>
245 - </li>
246 - <li>
247 - <h4 class="blockspare-sub-headings">
248 - <a href="https://blockspare.com/blog/"><?php esc_html_e('Latest Blog', 'blockspare') ?>
249 - →</a>
250 - </h4>
251 - <p><?php esc_html_e('Get latest articles about WordPress.', 'blockspare') ?></p>
252 - </li>
253 - </ul>
231 + )
232 + );
233 + }
254 234
255 - </p>
256 - </aside>
257 - </div>
258 235
259 - </div>
260 - </section>
261 -</div>
236 + public function blockspare_admin_blocks()
237 + {
238 +?>
239 + <div id="bs-starter-sites"></div>
240 +
241 + <?php
242 + }
243 +
244 + public function blockspare_admin_dashboard()
245 + {
246 + ?>
247 + <div id="bs-dashboard"></div>
248 +
249 +
250 + <?php
251 +
252 + }
253 +
254 + public function blockspare_admin_explore_more_blocks()
255 + {
256 +
257 + ?>
258 + <div id="bs-explore-more-dashboard"></div>
259 +
260 +
261 + <?php
262 + }
263 +
264 + public function blockspare_admin_change_log()
265 + {
266 + ?>
267 + <div id="bs-change-log"></div>
268 + <?php
269 +
270 + }
271 +
272 + public function blockspare_admin_free_vs_pro()
273 + {
274 + ?>
275 + <div id="bs-free-vs-pro"></div>
262 276 <?php
263 - }
264 277
265 - /**
266 - * Adds a marker to remember to redirect after activation.
267 - * Redirecting right away will not work.
268 - */
269 - public static function start_redirect_to_blockspare_page()
270 - {
271 - update_option('blockspare_redirect_to_welcome', '1');
272 - }
278 + }
273 279
274 - /**
275 - * Redirect to the welcome screen if our marker exists.
276 - */
277 - public function redirect_to_blockspare_page()
278 - {
279 - if (get_option('blockspare_redirect_to_welcome')) {
280 - delete_option('blockspare_redirect_to_welcome');
281 - wp_redirect(esc_url(admin_url('admin.php?page=blockspare')));
282 - die();
283 - }
284 - }
280 + /**
281 + * Adds a marker to remember to redirect after activation.
282 + * Redirecting right away will not work.
283 + */
284 + public static function start_redirect_to_blockspare_page()
285 + {
286 + update_option('blockspare_redirect_to_welcome', '1');
285 287 }
286 288
287 - new Blockspare_Admin_Dashboard();
289 + /**
290 + * Redirect to the welcome screen if our marker exists.
291 + */
292 + public function redirect_to_blockspare_page()
293 + {
294 + if (get_option('blockspare_redirect_to_welcome')) {
295 + delete_option('blockspare_redirect_to_welcome');
296 + wp_redirect(esc_url(admin_url('admin.php?page=blockspare')));
297 + die();
298 + }
299 + }
300 + }
301 +
302 + new Blockspare_Admin_Dashboard();
288 303 }
289 304
290 305 // Redirect to the welcome screen.
291 -register_activation_hook(BLOCKSPARE_BASE_FILE, array('Blockspare_Admin_Dashboard', 'start_redirect_to_blockspare_page'));
306 +register_activation_hook(BLOCKSPARE_BASE_FILE, array('Blockspare_Admin_Dashboard', 'start_redirect_to_blockspare_page'));