PluginProbe ʕ •ᴥ•ʔ
Essential Addons for Elementor – Popular Elementor Templates & Widgets / 2.8.5
Essential Addons for Elementor – Popular Elementor Templates & Widgets v2.8.5
6.6.5 6.6.4 6.6.3 5.7.3 5.7.4 5.8.0 5.8.1 5.8.10 5.8.11 5.8.12 5.8.13 5.8.14 5.8.15 5.8.16 5.8.18 5.8.2 5.8.3 5.8.4 5.8.5 5.8.6 5.8.7 5.8.8 5.8.9 5.9.0 5.9.1 5.9.10 5.9.11 5.9.12 5.9.13 5.9.14 5.9.15 5.9.16 5.9.17 5.9.18 5.9.19 5.9.2 5.9.20 5.9.21 5.9.22 5.9.23 5.9.24 5.9.25 5.9.26 5.9.27 5.9.3 5.9.4 5.9.5 5.9.6 5.9.7 5.9.8 5.9.9 6.0.0 6.0.1 6.0.10 6.0.11 6.0.12 6.0.13 6.0.14 6.0.15 6.0.2 6.0.3 6.0.4 6.0.5 6.0.6 6.0.7 6.0.8 6.0.9 6.1.0 6.1.1 6.1.10 6.1.11 trunk 6.1.12 1.0.0 6.1.13 1.0.1 6.1.14 1.1.0 6.1.15 2.0 6.1.17 2.1 6.1.18 2.10.0 6.1.19 2.10.1 6.1.2 2.10.2 6.1.20 2.10.3 6.1.3 2.10.4 6.1.4 2.10.5 6.1.5 2.2.0 6.1.6 2.2.1 6.1.7 2.2.2 6.1.8 2.2.3 6.1.9 2.2.4 6.2.0 2.2.5 6.2.1 2.3.0 6.2.2 2.3.1 6.2.3 2.4.0 6.2.4 2.4.1 6.3.0 2.4.2 6.3.1 2.4.3 6.3.2 2.5.0 6.3.3 2.6.0 6.4.0 2.7.0 6.5.0 2.7.1 6.5.1 2.7.10 6.5.10 2.7.11 6.5.11 2.7.2 6.5.12 2.7.3 6.5.13 2.7.4 6.5.2 2.7.5 6.5.3 2.7.6 6.5.4 2.7.7 6.5.5 2.7.8 6.5.6 2.7.9 6.5.7 2.8.0 6.5.8 2.8.1 6.5.9 2.8.2 6.6.0 2.8.3 6.6.1 2.8.4 6.6.2 2.8.5 2.8.6 2.8.7 2.9.0 2.9.1 2.9.2 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7 2.9.8 2.9.9 3.0.0 3.0.1 3.0.2 3.0.3 3.0.4 3.0.5 3.1.0 3.1.1 3.1.2 3.1.3 3.1.4 3.1.4.1 3.1.5 3.2.0 3.3.0 3.3.1 3.3.2 3.3.3 3.4.0 3.5.0 3.5.1 3.5.2 3.6.0 3.6.1 3.6.2 3.7.0 3.7.1 3.7.2 3.8.0 3.8.1 3.8.2 3.8.3 3.8.4 3.8.5 3.9.0 3.9.1 3.9.2 3.9.3 3.9.4 4.0.0 4.0.1 4.0.2 4.0.3 4.0.4 4.1.0 4.1.1 4.1.2 4.2.0 4.2.1 4.2.2 4.2.3 4.2.4 4.3.0 4.3.1 4.3.2 4.3.3 4.3.4 4.3.5 4.3.6 4.3.7 4.3.8 4.3.9 4.4.0 4.4.1 4.5.0 4.5.1 4.5.2 4.5.3 4.5.4 4.5.5 4.6.0 4.6.1 4.6.2 4.6.3 4.6.4 4.6.5 4.6.6 4.7.0 4.7.1 4.7.2 4.7.3 4.7.4 4.7.5 4.8.0 4.8.1 4.8.2 4.8.3 4.8.4 4.9.0 4.9.1 4.9.2 4.9.3 4.9.4 4.9.5 4.9.6 4.9.7 5.0.0 5.0.1 5.0.10 5.0.11 5.0.12 5.0.13 5.0.2 5.0.3 5.0.4 5.0.5 5.0.6 5.0.7 5.0.8 5.0.9 5.1.0 5.1.1 5.1.2 5.1.3 5.1.4 5.1.5 5.1.6 5.1.7 5.1.8 5.1.9 5.2.0 5.2.1 5.2.2 5.2.3 5.2.4 5.3.0 5.3.1 5.3.2 5.4.6 5.5.5 5.6.5 5.7.2
essential-addons-for-elementor-lite / admin / settings.php
essential-addons-for-elementor-lite / admin Last commit date
assets 7 years ago settings.php 7 years ago
settings.php
652 lines
1 <?php
2 /**
3 * Admin Settings Page
4 */
5
6 if( ! defined( 'ABSPATH' ) ) exit(); // Exit if accessed directly
7
8 class Eael_Admin_Settings {
9
10 private $is_pro = false;
11
12 /**
13 * Contains Default Component keys
14 * @var array
15 * @since 2.3.0
16 */
17 public $eael_default_keys = [ 'contact-form-7', 'count-down', 'creative-btn', 'fancy-text', 'post-grid', 'post-timeline', 'product-grid', 'team-members', 'testimonials', 'weforms', 'call-to-action', 'flip-box', 'info-box', 'dual-header', 'price-table', 'ninja-form', 'gravity-form', 'caldera-form', 'wpforms', 'twitter-feed', 'facebook-feed', 'data-table', 'filter-gallery', 'image-accordion', 'content-ticker', 'tooltip', 'adv-accordion', 'adv-tabs', 'progress-bar' ];
18
19 /**
20 * Will Contain All Components Default Values
21 * @var array
22 * @since 2.3.0
23 */
24 private $eael_default_settings;
25
26 /**
27 * Will Contain User End Settings Value
28 * @var array
29 * @since 2.3.0
30 */
31 private $eael_settings;
32
33 /**
34 * Will Contains Settings Values Fetched From DB
35 * @var array
36 * @since 2.3.0
37 */
38 private $eael_get_settings;
39
40 /**
41 * Initializing all default hooks and functions
42 * @param
43 * @return void
44 * @since 1.1.2
45 */
46 public function __construct() {
47
48 add_action( 'admin_menu', array( $this, 'create_eael_admin_menu' ), 600 );
49 add_action( 'init', array( $this, 'enqueue_eael_admin_scripts' ) );
50 add_action( 'wp_ajax_save_settings_with_ajax', array( $this, 'eael_save_settings_with_ajax' ) );
51 add_action( 'wp_ajax_add_action_with_ajax', array( $this, 'add_action_with_ajax' ) );
52
53 }
54
55 public function add_action_with_ajax(){
56
57 global $wp_version;
58 $post_types = [];
59 $remoteargs = array(
60 'timeout' => 5,
61 'redirection' => 5,
62 'httpversion' => '1.0',
63 'user-agent' => 'WordPress/' . $wp_version . '; ' . home_url(),
64 'blocking' => true,
65 'headers' => array(),
66 'cookies' => array(),
67 'sslverify' => false,
68 );
69 $otherurl = $_POST['url'];
70
71 $otherurl = $otherurl . 'wp-json/wp/v2/types';
72
73 $response = wp_remote_get( $otherurl, $remoteargs );
74 $response = json_decode( $response['body'] );
75 // echo '<pre>', print_r( $response, 1 ), '</pre>';
76 foreach( $response as $type ){
77 $post_types[ $type->rest_base ] = $type->name;
78 }
79 $eael_exclude_cpts = array( 'elementor_library', 'media', 'product' );
80 foreach ( $eael_exclude_cpts as $exclude_cpt ) {
81 unset($post_types[$exclude_cpt]);
82 }
83 // echo '<pre>', print_r( $post_types, 1 ), '</pre>';
84 echo json_encode( $post_types );
85
86 add_action( 'wp_ajax_save_facebook_feed_settings', array( $this, 'eael_save_facebook_feed_settings' ) );
87
88 }
89
90 /**
91 * Loading all essential scripts
92 * @param
93 * @return void
94 * @since 1.1.2
95 */
96 public function enqueue_eael_admin_scripts() {
97
98 wp_enqueue_style( 'essential_addons_elementor-notice-css', plugins_url( '/', __FILE__ ).'assets/css/eael-notice.css' );
99 if( isset( $_GET['page'] ) && $_GET['page'] == 'eael-settings' ) {
100 wp_enqueue_style( 'essential_addons_elementor-admin-css', plugins_url( '/', __FILE__ ).'assets/css/admin.css' );
101 wp_enqueue_style( 'essential_addons_elementor-sweetalert2-css', plugins_url( '/', __FILE__ ).'assets/vendor/sweetalert2/css/sweetalert2.min.css' );
102 wp_enqueue_script( 'essential_addons_elementor-admin-js', plugins_url( '/', __FILE__ ).'assets/js/admin.js', array( 'jquery'), '1.0', true );
103 wp_enqueue_script( 'essential_addons_core-js', plugins_url( '/', __FILE__ ).'assets/vendor/sweetalert2/js/core.js', array( 'jquery' ), '1.0', true );
104 wp_enqueue_script( 'essential_addons_sweetalert2-js', plugins_url( '/', __FILE__ ).'assets/vendor/sweetalert2/js/sweetalert2.min.js', array( 'jquery', 'essential_addons_core-js' ), '1.0', true );
105 }
106
107 }
108
109 /**
110 * Create an admin menu.
111 * @param
112 * @return void
113 * @since 1.1.2
114 */
115 public function create_eael_admin_menu() {
116
117 add_submenu_page(
118 'elementor',
119 'Essential Addons',
120 'Essential Addons',
121 'manage_options',
122 'eael-settings',
123 array( $this, 'eael_admin_settings_page' )
124 );
125
126 }
127
128 /**
129 * Create settings page.
130 * @param
131 * @return void
132 * @since 1.1.2
133 */
134 public function eael_admin_settings_page() {
135
136 $js_info = array(
137 'ajaxurl' => admin_url( 'admin-ajax.php' )
138 );
139 wp_localize_script( 'essential_addons_elementor-admin-js', 'js_eael_lite_settings', $js_info );
140
141 /**
142 * This section will handle the "eael_save_settings" array. If any new settings options is added
143 * then it will matches with the older array and then if it founds anything new then it will update the entire array.
144 */
145 $this->eael_default_settings = array_fill_keys( $this->eael_default_keys, true );
146 $this->eael_get_settings = get_option( 'eael_save_settings', $this->eael_default_settings );
147 $eael_new_settings = array_diff_key( $this->eael_default_settings, $this->eael_get_settings );
148
149 if( ! empty( $eael_new_settings ) ) {
150 $eael_updated_settings = array_merge( $this->eael_get_settings, $eael_new_settings );
151 update_option( 'eael_save_settings', $eael_updated_settings );
152 }
153 $this->eael_get_settings = get_option( 'eael_save_settings', $this->eael_default_settings );
154 ?>
155 <div class="eael-settings-wrap">
156 <form action="" method="POST" id="eael-settings" name="eael-settings">
157 <div class="eael-header-bar">
158 <div class="eael-header-left">
159 <div class="eael-admin-logo-inline">
160 <img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/ea-logo.svg'; ?>">
161 </div>
162 <h2 class="title"><?php _e( 'Essential Addons Settings', 'essential-addons-elementor' ); ?></h2>
163 </div>
164 <div class="eael-header-right">
165 <button type="submit" class="button eael-btn js-eael-settings-save"><?php _e('Save settings', 'essential-addons-elementor'); ?></button>
166 </div>
167 </div>
168 <div class="eael-settings-tabs">
169 <ul class="eael-tabs">
170 <li><a href="#general" class="active"><img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/icon-settings.svg'; ?>"><span>General</span></a></li>
171 <li><a href="#elements"><img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/icon-modules.svg'; ?>"><span>Elements</span></a></li>
172 <li><a href="#go-pro"><img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/icon-upgrade.svg'; ?>"><span>Go Premium</span></a></li>
173 </ul>
174 <div id="general" class="eael-settings-tab active">
175 <div class="row eael-admin-general-wrapper">
176 <div class="eael-admin-general-inner">
177 <div class="eael-admin-block-wrapper">
178
179 <div class="eael-admin-block eael-admin-block-banner">
180 <a href="https://essential-addons.com/elementor/" target="_blank">
181 <img class="eael-preview-img" src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/eael-featured.png'; ?>">
182 </a>
183 </div><!--preview image end-->
184 <div class="eael-admin-block eael-admin-block-docs">
185 <header class="eael-admin-block-header">
186 <div class="eael-admin-block-header-icon">
187 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 46"><defs><style>.cls-1{fill:#1abc9c;}</style></defs><title>Documentation</title><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><rect class="cls-1" x="15.84" y="17.13" width="14.32" height="1.59"/><rect class="cls-1" x="15.84" y="24.19" width="14.32" height="1.59"/><rect class="cls-1" x="15.84" y="20.66" width="14.32" height="1.59"/><path class="cls-1" d="M23,0A23,23,0,1,0,46,23,23,23,0,0,0,23,0Zm5.47,9.9,4.83,4.4H28.47Zm-2.29,23v3.2H15.49a2.79,2.79,0,0,1-2.79-2.79V12.69A2.79,2.79,0,0,1,15.49,9.9H27.28v5.59h6V27.72H15.84v1.59H29.78v1.94H15.84v1.59H26.19Zm11.29,2.52H33.88V39H31.37V35.42H27.78V32.9h3.59V29.31h2.52V32.9h3.59Z"/></g></g><head xmlns=""/></svg>
188 </div>
189 <h4 class="eael-admin-title">Documentation</h4>
190 </header>
191 <div class="eael-admin-block-content">
192 <p>Get started by spending some time with the documentation to get familiar with Essential Addons. Build awesome websites for you or your clients with ease.</a></p>
193 <a href="https://essential-addons.com/elementor/docs/" class="button button-primary" target="_blank">Documentation</a>
194 </div>
195 </div>
196 <div class="eael-admin-block eael-admin-block-contribution">
197 <header class="eael-admin-block-header">
198 <div class="eael-admin-block-header-icon">
199 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 45.69"><defs><style>.flexia-icon-bug{fill:#9b59b6;}</style></defs><title>Bugs</title><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path class="flexia-icon-bug" d="M18.87,28.37,9.16,38.08A8.66,8.66,0,0,0,14.49,40h4.38a9.55,9.55,0,0,0,2.28-.38v5.14a1,1,0,0,0,1.9,0v-5.9A4.83,4.83,0,0,0,25,37.31l.76-.76a.92.92,0,0,0,0-1.33Z"/><path class="flexia-icon-bug" d="M11.64,21.13c-.19-.19-.57-.38-.76-.19H9c-.38,0-.57,0-.76.38L7.07,23H1.17a1,1,0,1,0,0,1.9H6.31a9.56,9.56,0,0,0-.38,2.28V31.6a8.66,8.66,0,0,0,1.9,5.33l9.71-9.71Z"/><path class="flexia-icon-bug" d="M24.39,14.47c.19.19.38.19.76.19a.7.7,0,0,0,.57-.19.92.92,0,0,0,.38-1.14,11.08,11.08,0,0,1-1-3,.87.87,0,0,0-1-.76H22.3a1,1,0,0,0-.76.38,1.14,1.14,0,0,0-.19.76,2.35,2.35,0,0,0,.76,1.52Z"/><path class="flexia-icon-bug" d="M35.81,28.56h3.43a1,1,0,0,0,0-1.9H33.91L20.77,13.52A5.2,5.2,0,0,1,19.25,9.9V6.66a.9.9,0,0,0-1-1h-.19A13.52,13.52,0,0,0,16.21,3,9.12,9.12,0,0,0,9.54,0a9.71,9.71,0,0,0-5.9,2.09,1.44,1.44,0,0,0-.38.76,1,1,0,0,0,.38.76L9.54,7a5.39,5.39,0,0,1-2.86,4.19l-5.14-3a.85.85,0,0,0-1,0c-.38.19-.57.38-.57.76a8.9,8.9,0,0,0,2.67,7,9.53,9.53,0,0,0,6.85,3,4.1,4.1,0,0,0,2.09-.38L26.87,33.89,37.15,44.17a5.2,5.2,0,0,0,3.62,1.52,5,5,0,0,0,4.95-4.95,5.2,5.2,0,0,0-1.52-3.62Z"/><path class="flexia-icon-bug" d="M34.86,24.75c.19.19.38.19.76.19H36a1,1,0,0,0,.57-1V21.51c0-.38-.38-1-.76-1a7,7,0,0,1-3.43-.76.92.92,0,0,0-1.14.38c-.19.38-.19,1,.19,1.14Z"/><path class="flexia-icon-bug" d="M45.71,9.9c-1.52-1.52-5.14-.38-7,.57L35.81,7.62c.76-2.09,1.9-5.71.57-7a.92.92,0,0,0-1.33,0,.92.92,0,0,0,0,1.33c.38.38,0,2.67-1,5.14L28,8a.87.87,0,0,0-.76,1C26.87,14.28,31.63,19,37.34,19c.38,0,1-.38,1-.76l1-6.09c2.47-1,4.76-1.33,5.14-1A.94.94,0,1,0,45.71,9.9Z"/></g></g><head xmlns=""/></svg>
200 </div>
201 <h4 class="eael-admin-title">Contribute to Essential Addons</h4>
202 </header>
203 <div class="eael-admin-block-content">
204 <p>You can contribute to make Essential Addons better reporting bugs, creating issues, pull requests at <a href="https://github.com/rupok/essential-addons-elementor-lite/" target="_blank">Github.</a></p>
205 <a href="https://github.com/rupok/essential-addons-elementor-lite/issues/new" class="button button-primary" target="_blank">Report a bug</a>
206 </div>
207 </div>
208 <div class="eael-admin-block eael-admin-block-support">
209 <header class="eael-admin-block-header">
210 <div class="eael-admin-block-header-icon">
211 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32.22 42.58"><defs><style>.flexia-icon-support{fill:#6c75ff;}</style></defs><title>Flexia Support</title><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path class="flexia-icon-support" d="M6.36,29.34l1.09-1.09h8l-5.08-9.18-3.76.76a2.64,2.64,0,0,0-2,1.91L.09,36.31a2.64,2.64,0,0,0,2.55,3.31H6.36V29.34Z"/><path class="flexia-icon-support" d="M32.13,36.31,27.67,21.75a2.64,2.64,0,0,0-2.06-1.92l-3.74-.71-5.06,9.13h8.56l1.09,1.09V39.62h3.12a2.64,2.64,0,0,0,2.55-3.31Z"/><polygon class="flexia-icon-support" points="8.54 39.62 8.24 39.62 8.24 39.62 23.98 39.62 23.98 39.62 24.28 39.62 24.28 30.43 8.54 30.43 8.54 39.62"/><rect class="flexia-icon-support" x="4.19" y="40.61" width="23.83" height="1.97"/><path class="flexia-icon-support" d="M7.62,12.65c0,.09.1.22.15.36a3.58,3.58,0,0,0,.68,1.22c1.21,3.94,4.33,6.68,7.64,6.67s6.38-2.77,7.55-6.72A3.61,3.61,0,0,0,24.31,13c.06-.14.11-.27.15-.36a2,2,0,0,0-.33-2.41V10.1C24.12,5.2,23.48,0,16,0S7.92,5,7.94,10.15c0,0,0,.06,0,.09A2,2,0,0,0,7.62,12.65Zm1-1.58h0A.55.55,0,0,0,9,10.83l1.3.2a.28.28,0,0,0,.3-.16L11.39,9a35.31,35.31,0,0,0,7.2,1,7.76,7.76,0,0,0,2.11-.25L21.23,11a.27.27,0,0,0,.25.17h.07l1.51-.43a.56.56,0,0,0,.31.3h0c.23.11.3.6.06,1.09-.06.12-.12.27-.18.43a4.18,4.18,0,0,1-.4.82.55.55,0,0,0-.26.33c-1,3.58-3.68,6.08-6.54,6.09s-5.6-2.48-6.63-6a.55.55,0,0,0-.26-.33,4.3,4.3,0,0,1-.41-.82c-.06-.15-.13-.3-.18-.42C8.37,11.68,8.44,11.19,8.67,11.08Z"/></g></g><head xmlns=""/></svg>
212 </div>
213 <h4 class="eael-admin-title">Need Help?</h4>
214 </header>
215 <div class="eael-admin-block-content">
216 <p>Stuck with something? Get help from the community on <a href="https://community.wpdeveloper.net/" target="_blank">WPDeveloper Forum</a> or <a href="https://www.facebook.com/groups/essentialaddons/" target="_blank">Facebook Community.</a> In case of emergency, initiate a live chat at <a href="https://essential-addons.com/elementor/" target="_blank">Essential Addons website.</a></p>
217 <a href="https://community.wpdeveloper.net/support-forum/forum/essential-addons-for-elementor/" class="button button-primary" target="_blank">Get Community Support</a>
218 </div>
219 </div>
220 <div class="eael-admin-block eael-admin-block-review">
221 <header class="eael-admin-block-header">
222 <div class="eael-admin-block-header-icon">
223 <svg style="enable-background:new 0 0 48 48;" version="1.1" viewBox="0 0 48 48" xml:space="preserve" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g id="Icons"><g><g id="Icons_7_"><g><path d="M35.72935,25.74662l0.8357-0.8271c1.611-1.611,2.4122-3.7475,2.4122-5.8668 c0-2.1279-0.8012-4.2558-2.4122-5.8668c-3.2221-3.2221-8.5031-3.2221-11.7337,0l-0.8271,0.8356l-0.8356-0.8356 c-3.222-3.2221-8.5031-3.2221-11.7251,0c-1.6196,1.611-2.4208,3.7389-2.4208,5.8668c0,2.1193,0.8012,4.2558,2.4208,5.8668 l0.8271,0.8271l11.3076,11.3077c0.2353,0.2352,0.6167,0.2351,0.8519-0.0002L35.72935,25.74662" style="fill:#EF4B53;"/></g></g><path d="M17.80325,12.24382c0,0-6.9318-0.5491-7.6524,7.3092c0,0,1.4413-5.765,7.8583-5.4905 c0,0,1.5941,0.1605,1.5901-0.8317C19.59495,12.14722,17.80325,12.24382,17.80325,12.24382z" style="fill:#F47682;"/></g></g></svg>
224 </div>
225 <h4 class="eael-admin-title">Show your Love</h4>
226 </header>
227 <div class="eael-admin-block-content">
228 <p>We love to have you in Essential Addons family. We are making it more awesome everyday. Take your 2 minutes to review the plugin and spread the love to encourage us to keep it going.</p>
229
230 <a href="https://wpdeveloper.net/review-essential-addons-elementor" class="review-flexia button button-primary" target="_blank">Leave a Review</a>
231 </div>
232 </div>
233 </div><!--admin block-wrapper end-->
234 </div>
235 <div class="eael-admin-sidebar">
236 <div class="eael-sidebar-block">
237 <div class="eael-admin-sidebar-logo">
238 <img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/ea-logo.svg'; ?>">
239 </div>
240 <div class="eael-admin-sidebar-cta">
241 <?php printf( __( '<a href="%s" target="_blank">Upgrade to Pro</a>', 'essential-addons-elementor' ), 'https://wpdeveloper.net/in/upgrade-essential-addons-elementor' ); ?>
242 </div>
243 </div>
244 </div><!--admin sidebar end-->
245 </div><!--Row end-->
246 </div>
247 <div id="elements" class="eael-settings-tab">
248 <div class="row">
249 <div class="col-full">
250 <p class="eael-elements-control-notice">You can disable the elements you are not using on your site. That will disable all associated assets of those widgets to improve your site loading.</p>
251 <div class="eael-checkbox-container">
252 <div class="eael-checkbox">
253 <input type="checkbox" id="contact-form-7" name="contact-form-7" <?php checked( 1, $this->eael_get_settings['contact-form-7'], true ); ?> >
254 <label for="contact-form-7"></label>
255 <p class="eael-el-title"><?php _e( 'Contact Form 7', 'essential-addons-elementor' ); ?></p>
256 </div>
257 <div class="eael-checkbox">
258 <input type="checkbox" id="count-down" name="count-down" <?php checked( 1, $this->eael_get_settings['count-down'], true ); ?> >
259 <label for="count-down"></label>
260
261 <p class="eael-el-title"><?php _e( 'Count Down', 'essential-addons-elementor' ); ?></p>
262 </div>
263 <div class="eael-checkbox">
264 <input type="checkbox" id="creative-btn" name="creative-btn" <?php checked( 1, $this->eael_get_settings['creative-btn'], true ); ?> >
265 <label for="creative-btn"></label>
266 <p class="eael-el-title"><?php _e( 'Creative Button', 'essential-addons-elementor' ); ?></p>
267 </div>
268 <div class="eael-checkbox">
269 <input type="checkbox" id="fancy-text" name="fancy-text" <?php checked( 1, $this->eael_get_settings['fancy-text'], true ); ?> >
270 <label for="fancy-text"></label>
271 <p class="eael-el-title"><?php _e( 'Fancy Text', 'essential-addons-elementor' ); ?></p>
272 </div>
273 <div class="eael-checkbox">
274 <input type="checkbox" id="post-grid" name="post-grid" <?php checked( 1, $this->eael_get_settings['post-grid'], true ); ?> >
275 <label for="post-grid"></label>
276 <p class="eael-el-title"><?php _e( 'Post Grid', 'essential-addons-elementor' ); ?></p>
277 </div>
278 <div class="eael-checkbox">
279 <input type="checkbox" id="post-timeline" name="post-timeline" <?php checked( 1, $this->eael_get_settings['post-timeline'], true ); ?> >
280 <label for="post-timeline"></label>
281 <p class="eael-el-title"><?php _e( 'Post Timeline', 'essential-addons-elementor' ) ?></p>
282 </div>
283 <div class="eael-checkbox">
284 <input type="checkbox" id="product-grid" name="product-grid" <?php checked( 1, $this->eael_get_settings['product-grid'], true ); ?> >
285 <label for="product-grid"></label>
286 <p class="eael-el-title"><?php _e( 'Product Grid', 'essential-addons-elementor' ) ?></p>
287 </div>
288 <div class="eael-checkbox">
289 <input type="checkbox" id="team-members" name="team-members" <?php checked( 1, $this->eael_get_settings['team-members'], true ); ?> >
290 <label for="team-members"></label>
291 <p class="eael-el-title"><?php _e( 'Team Member', 'essential-addons-elementor' ) ?></p>
292 </div>
293 <div class="eael-checkbox">
294 <input type="checkbox" id="testimonials" name="testimonials" <?php checked( 1, $this->eael_get_settings['testimonials'], true ); ?> >
295 <label for="testimonials"></label>
296 <p class="eael-el-title"><?php _e( 'Testimonials', 'essential-addons-elementor' ) ?></p>
297 </div>
298 <div class="eael-checkbox">
299 <input type="checkbox" id="weforms" name="weforms" <?php checked( 1, $this->eael_get_settings['weforms'], true ); ?> >
300 <label for="weforms"></label>
301 <p class="eael-el-title"><?php _e( 'weForms', 'essential-addons-elementor' ) ?></p>
302 </div>
303 <div class="eael-checkbox">
304 <input type="checkbox" id="call-to-action" name="call-to-action" <?php checked( 1, $this->eael_get_settings['call-to-action'], true ); ?> >
305 <label for="call-to-action"></label>
306 <p class="eael-el-title"><?php _e( 'Call To Action', 'essential-addons-elementor' ) ?></p>
307 </div>
308 <div class="eael-checkbox">
309 <input type="checkbox" id="flip-box" name="flip-box" <?php checked( 1, $this->eael_get_settings['flip-box'], true ); ?> >
310 <label for="flip-box"></label>
311 <p class="eael-el-title"><?php _e( 'Flip Box', 'essential-addons-elementor' ) ?></p>
312 </div>
313 <div class="eael-checkbox">
314 <input type="checkbox" id="info-box" name="info-box" <?php checked( 1, $this->eael_get_settings['info-box'], true ); ?> >
315 <label for="info-box"></label>
316 <p class="eael-el-title"><?php _e( 'Info Box', 'essential-addons-elementor' ) ?></p>
317 </div>
318 <div class="eael-checkbox">
319 <input type="checkbox" id="dual-header" name="dual-header" <?php checked( 1, $this->eael_get_settings['dual-header'], true ); ?> >
320 <label for="dual-header"></label>
321 <p class="eael-el-title"><?php _e( 'Dual Color Header', 'essential-addons-elementor' ) ?></p>
322 </div>
323 <div class="eael-checkbox">
324 <input type="checkbox" id="price-table" name="price-table" <?php checked( 1, $this->eael_get_settings['price-table'], true ); ?> >
325 <label for="price-table"></label>
326 <p class="eael-el-title"><?php _e( 'Pricing Table', 'essential-addons-elementor' ) ?></p>
327 </div>
328 <div class="eael-checkbox">
329 <input type="checkbox" id="ninja-form" name="ninja-form" <?php checked( 1, $this->eael_get_settings['ninja-form'], true ); ?> >
330 <label for="ninja-form"></label>
331 <p class="eael-el-title"><?php _e( 'Ninja Form', 'essential-addons-elementor' ) ?></p>
332 </div>
333 <div class="eael-checkbox">
334 <input type="checkbox" id="gravity-form" name="gravity-form" <?php checked( 1, $this->eael_get_settings['gravity-form'], true ); ?> >
335 <label for="gravity-form"></label>
336 <p class="eael-el-title"><?php _e( 'Gravity Form', 'essential-addons-elementor' ) ?></p>
337 </div>
338 <div class="eael-checkbox">
339 <input type="checkbox" id="caldera-form" name="caldera-form" <?php checked( 1, $this->eael_get_settings['caldera-form'], true ); ?> >
340 <label for="caldera-form"></label>
341 <p class="eael-el-title"><?php _e( 'Caldera Form', 'essential-addons-elementor' ) ?></p>
342 </div>
343 <div class="eael-checkbox">
344 <input type="checkbox" id="wpforms" name="wpforms" <?php checked( 1, $this->eael_get_settings['wpforms'], true ); ?> >
345 <label for="wpforms"></label>
346 <p class="eael-el-title"><?php _e( 'WPForms', 'essential-addons-elementor' ) ?></p>
347 </div>
348 <div class="eael-checkbox">
349 <input type="checkbox" id="twitter-feed" name="twitter-feed" <?php checked( 1, $this->eael_get_settings['twitter-feed'], true ); ?> >
350 <label for="twitter-feed"></label>
351 <p class="eael-el-title"><?php _e( 'Twitter Feed', 'essential-addons-elementor' ) ?></p>
352 </div>
353 <div class="eael-checkbox">
354 <input type="checkbox" id="facebook-feed" name="facebook-feed" <?php checked( 1, $this->eael_get_settings['facebook-feed'], true ); ?> >
355 <label for="facebook-feed"></label>
356 <p class="eael-el-title"><?php _e( 'Facebook Feed', 'essential-addons-elementor' ) ?></p>
357 </div>
358 <div class="eael-checkbox">
359 <input type="checkbox" id="filter-gallery" name="filter-gallery" <?php checked( 1, $this->eael_get_settings['filter-gallery'], true ); ?> >
360 <label for="filter-gallery"></label>
361 <p class="eael-el-title"><?php _e( 'Filterable Gallery', 'essential-addons-elementor' ) ?></p>
362 </div>
363 <div class="eael-checkbox">
364 <input type="checkbox" id="data-table" name="data-table" <?php checked( 1, $this->eael_get_settings['data-table'], true ); ?> >
365 <label for="data-table"></label>
366 <p class="eael-el-title"><?php _e( 'Data Table', 'essential-addons-elementor' ) ?></p>
367 </div>
368 <div class="eael-checkbox">
369 <input type="checkbox" id="image-accordion" name="image-accordion" <?php checked( 1, $this->eael_get_settings['image-accordion'], true ); ?> >
370 <label for="image-accordion"></label>
371 <p class="eael-el-title"><?php _e( 'Image Accordion', 'essential-addons-elementor' ) ?></p>
372 </div>
373 <div class="eael-checkbox">
374 <input type="checkbox" id="content-ticker" name="content-ticker" <?php checked( 1, $this->eael_get_settings['content-ticker'], true ); ?> >
375 <label for="content-ticker"></label>
376 <p class="eael-el-title"><?php _e( 'Content Ticker', 'essential-addons-elementor' ) ?></p>
377 </div>
378 <div class="eael-checkbox">
379 <input type="checkbox" id="tooltip" name="tooltip" <?php checked( 1, $this->eael_get_settings['tooltip'], true ); ?> >
380 <label for="tooltip"></label>
381 <p class="eael-el-title"><?php _e( 'Tooltip', 'essential-addons-elementor' ) ?></p>
382 </div>
383 <div class="eael-checkbox">
384 <input type="checkbox" id="adv-accordion" name="adv-accordion" <?php checked( 1, $this->eael_get_settings['adv-accordion'], true ); ?> >
385 <label for="adv-accordion"></label>
386 <p class="eael-el-title"><?php _e( 'Advanced Accordion', 'essential-addons-elementor' ) ?></p>
387 </div>
388 <div class="eael-checkbox">
389 <input type="checkbox" id="adv-tabs" name="adv-tabs" <?php checked( 1, $this->eael_get_settings['adv-tabs'], true ); ?> >
390 <label for="adv-tabs"></label>
391 <p class="eael-el-title"><?php _e( 'Advanced Tabs', 'essential-addons-elementor' ) ?></p>
392 </div>
393 <div class="eael-checkbox">
394 <input type="checkbox" id="progress-bar" name="progress-bar" <?php checked( 1, $this->eael_get_settings['progress-bar'], true ); ?> >
395 <label for="progress-bar"></label>
396 <p class="eael-el-title"><?php _e( 'Progress Bar', 'essential-addons-elementor' ) ?></p>
397 </div>
398 </div><!--./checkbox-container-->
399 </div>
400 <div class="col-full">
401 <div class="premium-elements-title">
402 <img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/lock-icon.png'; ?>">
403 <h4 class="section-title">Premium Elements</h4>
404 </div>
405 <div class="eael-checkbox-container">
406 <div class="eael-checkbox">
407 <input type="checkbox" id="img-comparison" name="img-comparison" disabled>
408 <label for="img-comparison" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
409 <p class="eael-el-title">
410 <?php _e( 'Image Comparison', 'essential-addons-elementor' ); ?>
411 </p>
412 </div>
413 <div class="eael-checkbox">
414 <input type="checkbox" id="instagram-gallery" name="instagram-gallery" disabled>
415 <label for="instagram-gallery" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
416 <p class="eael-el-title">
417 <?php _e( 'Instagram Gallery', 'essential-addons-elementor' ); ?>
418 </p>
419 </div>
420 <div class="eael-checkbox">
421 <input type="checkbox" id="interactive-promo" name="interactive-promo" disabled>
422 <label for="interactive-promo" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
423 <p class="eael-el-title">
424 <?php _e( 'Interactive Promo', 'essential-addons-elementor' ); ?>
425 </p>
426 </div>
427 <div class="eael-checkbox">
428 <input type="checkbox" id="lightbox" name="lightbox" disabled>
429 <label for="lightbox" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
430 <p class="eael-el-title">
431 <?php _e( 'Lightbox', 'essential-addons-elementor' ); ?>
432 </p>
433 </div>
434 <div class="eael-checkbox">
435 <input type="checkbox" id="post-block" name="post-block" disabled>
436 <label for="post-block" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
437 <p class="eael-el-title">
438 <?php _e( 'Post Block', 'essential-addons-elementor' ); ?>
439 </p>
440 </div>
441 <div class="eael-checkbox">
442 <input type="checkbox" id="testimonial-slider" name="testimonial-slider" disabled>
443 <label for="testimonial-slider" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
444 <p class="eael-el-title">
445 <?php _e( 'Testimonial Slider', 'essential-addons-elementor' ) ?>
446 </p>
447 </div>
448 <div class="eael-checkbox">
449 <input type="checkbox" id="static-product" name="static-product" disabled>
450 <label for="static-product" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
451 <p class="eael-el-title">
452 <?php _e( 'Static Product', 'essential-addons-elementor' ) ?>
453 </p>
454 </div>
455 <div class="eael-checkbox">
456 <input type="checkbox" id="flip-carousel" name="flip-carousel" disabled>
457 <label for="flip-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
458 <p class="eael-el-title">
459 <?php _e( 'Flip Carousel', 'essential-addons-elementor' ) ?>
460 </p>
461 </div>
462 <div class="eael-checkbox">
463 <input type="checkbox" id="interactive-cards" name="interactive-cards" disabled>
464 <label for="interactive-cards" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
465 <p class="eael-el-title">
466 <?php _e( 'Interactive Cards', 'essential-addons-elementor' ) ?>
467 </p>
468 </div>
469 <div class="eael-checkbox">
470 <input type="checkbox" id="content-timeline" name="content-timeline" disabled>
471 <label for="content-timeline" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
472 <p class="eael-el-title">
473 <?php _e( 'Content Timeline', 'essential-addons-elementor' ) ?>
474 </p>
475 </div>
476 <div class="eael-checkbox">
477 <input type="checkbox" id="twitter-feed-carousel" name="twitter-feed-carousel" disabled>
478 <label for="twitter-feed-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
479 <p class="eael-el-title">
480 <?php _e( 'Twitter Feed Carousel', 'essential-addons-elementor' ) ?>
481 </p>
482 </div>
483 <div class="eael-checkbox">
484 <input type="checkbox" id="facebook-feed-carousel" name="facebook-feed-carousel" disabled>
485 <label for="facebook-feed-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
486 <p class="eael-el-title">
487 <?php _e( 'Facebook Feed Carousel', 'essential-addons-elementor' ) ?>
488 </p>
489 </div>
490 <div class="eael-checkbox">
491 <input type="checkbox" id="dynamic-filter-gallery" name="dynamic-filter-gallery" disabled>
492 <label for="dynamic-filter-gallery" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
493 <p class="eael-el-title">
494 <?php _e( 'Dynamic Filter Gallery', 'essential-addons-elementor' ) ?>
495 </p>
496 </div>
497 <div class="eael-checkbox">
498 <input type="checkbox" id="post-list" name="post-list" disabled>
499 <label for="post-list" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
500 <p class="eael-el-title">
501 <?php _e( 'Smart Post List', 'essential-addons-elementor' ) ?>
502 </p>
503 </div>
504 <div class="eael-checkbox">
505 <input type="checkbox" id="adv-google-map" name="adv-google-map" disabled>
506 <label for="adv-google-map" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
507 <p class="eael-el-title">
508 <?php _e( 'Advanced Google Map', 'essential-addons-elementor' ) ?>
509 </p>
510 </div>
511 <div class="eael-checkbox">
512 <input type="checkbox" id="toggle" name="toggle" disabled>
513 <label for="toggle" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
514 <p class="eael-el-title">
515 <?php _e( 'Content Toggle', 'essential-addons-elementor' ) ?>
516 </p>
517 </div>
518 <div class="eael-checkbox">
519 <input type="checkbox" id="mailchimp" name="mailchimp" disabled>
520 <label for="mailchimp" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
521 <p class="eael-el-title">
522 <?php _e( 'Mailchimp', 'essential-addons-elementor' ) ?>
523 </p>
524 </div>
525 <div class="eael-checkbox">
526 <input type="checkbox" id="divider" name="divider" disabled>
527 <label for="divider" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
528 <p class="eael-el-title">
529 <?php _e( 'Divider', 'essential-addons-elementor' ) ?>
530 </p>
531 </div>
532 <div class="eael-checkbox">
533 <input type="checkbox" id="price-menu" name="price-menu" disabled>
534 <label for="price-menu" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
535 <p class="eael-el-title">
536 <?php _e( 'Price Menu', 'essential-addons-elementor' ) ?>
537 </p>
538 </div>
539 <div class="eael-checkbox">
540 <input type="checkbox" id="image-hotspots" name="image-hotspots" disabled>
541 <label for="image-hotspots" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
542 <p class="eael-el-title">
543 <?php _e( 'Image Hotspots', 'essential-addons-elementor' ) ?>
544 </p>
545 </div>
546 <div class="eael-checkbox">
547 <input type="checkbox" id="one-page-navigation" name="one-page-navigation" disabled>
548 <label for="one-page-navigation" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
549 <p class="eael-el-title">
550 <?php _e( 'One Page Navigation', 'essential-addons-elementor' ) ?>
551 </p>
552 </div>
553 <div class="eael-checkbox">
554 <input type="checkbox" id="counter" name="counter" disabled>
555 <label for="counter" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
556 <p class="eael-el-title">
557 <?php _e( 'Counter', 'essential-addons-elementor' ) ?>
558 </p>
559 </div>
560 <div class="eael-checkbox">
561 <input type="checkbox" id="post-carousel" name="post-carousel" disabled>
562 <label for="post-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
563 <p class="eael-el-title">
564 <?php _e( 'Post Carousel', 'essential-addons-elementor' ) ?>
565 </p>
566 </div>
567 <div class="eael-checkbox">
568 <input type="checkbox" id="team-member-carousel" name="team-member-carousel" disabled>
569 <label for="team-member-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
570 <p class="eael-el-title">
571 <?php _e( 'Team Member Carousel', 'essential-addons-elementor' ) ?>
572 </p>
573 </div>
574 <div class="eael-checkbox">
575 <input type="checkbox" id="logo-carousel" name="logo-carousel" disabled>
576 <label for="logo-carousel" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
577 <p class="eael-el-title">
578 <?php _e( 'Logo Carousel', 'essential-addons-elementor' ) ?>
579 </p>
580 </div>
581 <div class="eael-checkbox">
582 <input type="checkbox" id="protected-content" name="protected-content" disabled>
583 <label for="protected-content" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
584 <p class="eael-el-title">
585 <?php _e( 'Protected Content', 'essential-addons-elementor' ) ?>
586 </p>
587 </div>
588 <div class="eael-checkbox">
589 <input type="checkbox" id="offcanvas" name="offcanvas" disabled>
590 <label for="offcanvas" class="<?php if( (bool) $this->is_pro === false ) : echo 'eael-get-pro'; endif; ?>"></label>
591 <p class="eael-el-title">
592 <?php _e( 'Offcanvas Content', 'essential-addons-elementor' ) ?>
593 </p>
594 </div>
595 </div><!--./checkbox-container-->
596 <div class="eael-save-btn-wrap">
597 <button type="submit" class="button eael-btn js-eael-settings-save"><?php _e('Save settings', 'essential-addons-elementor'); ?></button>
598 </div>
599 </div>
600 </div>
601 </div>
602 <div id="go-pro" class="eael-settings-tab">
603 <div class="row go-premium">
604 <div class="col-half">
605 <h4>Why upgrade to Premium Version?</h4>
606 <p>The premium version helps us to continue development of the product incorporating even more features and enhancements.</p>
607
608 <p>You will also get world class support from our dedicated team, 24/7.</p>
609
610 <a href="https://wpdeveloper.net/in/upgrade-essential-addons-elementor" target="_blank" class="button eael-btn eael-license-btn">Get Premium Version</a>
611 </div>
612 </div>
613 </div>
614 </div>
615 </form>
616 </div>
617 <?php
618
619 }
620
621 /**
622 * Saving data with ajax request
623 * @param
624 * @return array
625 * @since 1.1.2
626 */
627 public function eael_save_settings_with_ajax() {
628
629 if( isset( $_POST['fields'] ) ) {
630 parse_str( $_POST['fields'], $settings );
631 }else {
632 return;
633 }
634
635 $this->eael_settings = [];
636
637 foreach( $this->eael_default_keys as $key ){
638 if( isset( $settings[ $key ] ) ) {
639 $this->eael_settings[ $key ] = 1;
640 } else {
641 $this->eael_settings[ $key ] = 0;
642 }
643 }
644 update_option( 'eael_save_settings', $this->eael_settings );
645 return true;
646 die();
647
648 }
649
650 }
651
652 new Eael_Admin_Settings();