PluginProbe ʕ •ᴥ•ʔ
Royal Addons for Elementor – Addons and Templates Kit for Elementor / 1.7.1064
Royal Addons for Elementor – Addons and Templates Kit for Elementor v1.7.1064
1.7.1064 1.7.1063 1.7.1062 1.7.1061 1.7.1060 1.7.1059 1.7.1058 trunk 1.0.0 1.1.0 1.2 1.3 1.3.1 1.3.2 1.3.21 1.3.22 1.3.23 1.3.24 1.3.25 1.3.26 1.3.27 1.3.28 1.3.29 1.3.30 1.3.31 1.3.32 1.3.33 1.3.34 1.3.35 1.3.36 1.3.37 1.3.38 1.3.39 1.3.40 1.3.41 1.3.42 1.3.43 1.3.44 1.3.45 1.3.46 1.3.47 1.3.48 1.3.49 1.3.50 1.3.51 1.3.52 1.3.53 1.3.54 1.3.55 1.3.56 1.3.57 1.3.58 1.3.59 1.3.60 1.3.61 1.3.62 1.3.63 1.3.64 1.3.65 1.3.66 1.3.67 1.3.68 1.3.69 1.3.70 1.3.71 1.3.72 1.3.73 1.3.74 1.3.75 1.3.76 1.3.77 1.3.78 1.3.79 1.3.80 1.3.81 1.3.82 1.3.83 1.3.84 1.3.85 1.3.86 1.3.87 1.3.88 1.3.89 1.3.90 1.3.91 1.3.92 1.3.93 1.3.94 1.3.95 1.3.96 1.3.97 1.3.971 1.3.972 1.3.973 1.3.974 1.3.975 1.3.976 1.3.977 1.3.978 1.3.979 1.3.980 1.3.981 1.3.982 1.3.983 1.3.984 1.3.985 1.3.986 1.3.987 1.7.1 1.7.1001 1.7.1002 1.7.1003 1.7.1004 1.7.1005 1.7.1006 1.7.1007 1.7.1008 1.7.1009 1.7.1010 1.7.1011 1.7.1012 1.7.1013 1.7.1014 1.7.1015 1.7.1016 1.7.1017 1.7.1018 1.7.1019 1.7.1020 1.7.1021 1.7.1022 1.7.1023 1.7.1024 1.7.1025 1.7.1026 1.7.1027 1.7.1028 1.7.1029 1.7.1030 1.7.1031 1.7.1032 1.7.1033 1.7.1034 1.7.1035 1.7.1036 1.7.1037 1.7.1038 1.7.1039 1.7.1040 1.7.1041 1.7.1042 1.7.1043 1.7.1044 1.7.1045 1.7.1046 1.7.1047 1.7.1048 1.7.1049 1.7.1050 1.7.1051 1.7.1052 1.7.1053 1.7.1054 1.7.1055 1.7.1056 1.7.1057
royal-elementor-addons / freemius / config.php
royal-elementor-addons / freemius Last commit date
assets 5 days ago includes 5 days ago languages 5 days ago templates 5 days ago LICENSE.txt 5 days ago README.md 5 days ago composer.json 5 days ago config.php 5 days ago index.php 5 days ago require.php 5 days ago start.php 5 days ago
config.php
392 lines
1 <?php
2 /**
3 * @package Freemius
4 * @copyright Copyright (c) 2015, Freemius, Inc.
5 * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
6 * @since 1.0.4
7 */
8
9 if ( ! defined( 'ABSPATH' ) ) {
10 exit;
11 }
12
13 if ( ! defined( 'WP_FS__SLUG' ) ) {
14 define( 'WP_FS__SLUG', 'freemius' );
15 }
16 if ( ! defined( 'WP_FS__DEV_MODE' ) ) {
17 define( 'WP_FS__DEV_MODE', false );
18 }
19
20 #--------------------------------------------------------------------------------
21 #region API Connectivity Issues Simulation
22 #--------------------------------------------------------------------------------
23
24 if ( ! defined( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY' ) ) {
25 define( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY', false );
26 }
27 if ( ! defined( 'WP_FS__SIMULATE_NO_CURL' ) ) {
28 define( 'WP_FS__SIMULATE_NO_CURL', false );
29 }
30 if ( ! defined( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY_CLOUDFLARE' ) ) {
31 define( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY_CLOUDFLARE', false );
32 }
33 if ( ! defined( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY_SQUID_ACL' ) ) {
34 define( 'WP_FS__SIMULATE_NO_API_CONNECTIVITY_SQUID_ACL', false );
35 }
36 if ( WP_FS__SIMULATE_NO_CURL ) {
37 define( 'FS_SDK__SIMULATE_NO_CURL', true );
38 }
39 if ( WP_FS__SIMULATE_NO_API_CONNECTIVITY_CLOUDFLARE ) {
40 define( 'FS_SDK__SIMULATE_NO_API_CONNECTIVITY_CLOUDFLARE', true );
41 }
42 if ( WP_FS__SIMULATE_NO_API_CONNECTIVITY_SQUID_ACL ) {
43 define( 'FS_SDK__SIMULATE_NO_API_CONNECTIVITY_SQUID_ACL', true );
44 }
45
46 #endregion
47
48 if ( ! defined( 'WP_FS__SIMULATE_FREEMIUS_OFF' ) ) {
49 define( 'WP_FS__SIMULATE_FREEMIUS_OFF', false );
50 }
51
52 if ( ! defined( 'WP_FS__PING_API_ON_IP_OR_HOST_CHANGES' ) ) {
53 /**
54 * @since 1.1.7.3
55 * @author Vova Feldman (@svovaf)
56 *
57 * I'm not sure if shared servers periodically change IP, or the subdomain of the
58 * admin dashboard. Also, I've seen sites that have strange loop of switching
59 * between domains on a daily basis. Therefore, to eliminate the risk of
60 * multiple unwanted connectivity test pings, temporary ignore domain or
61 * server IP changes.
62 */
63 define( 'WP_FS__PING_API_ON_IP_OR_HOST_CHANGES', false );
64 }
65
66 /**
67 * If your dev environment supports custom public network IP setup
68 * like VVV, please update WP_FS__LOCALHOST_IP with your public IP
69 * and uncomment it during dev.
70 */
71 if ( ! defined( 'WP_FS__LOCALHOST_IP' ) ) {
72 // VVV default public network IP.
73 define( 'WP_FS__VVV_DEFAULT_PUBLIC_IP', '192.168.50.4' );
74
75 // define( 'WP_FS__LOCALHOST_IP', WP_FS__VVV_DEFAULT_PUBLIC_IP );
76 }
77
78 /**
79 * If true and running with secret key, the opt-in process
80 * will skip the email activation process which is invoked
81 * when the email of the context user already exist in Freemius
82 * database (as a security precaution, to prevent sharing user
83 * secret with unauthorized entity).
84 *
85 * IMPORTANT:
86 * AS A SECURITY PRECAUTION, WE VALIDATE THE TIMESTAMP OF THE OPT-IN REQUEST.
87 * THEREFORE, MAKE SURE THAT WHEN USING THIS PARAMETER,YOUR TESTING ENVIRONMENT'S
88 * CLOCK IS SYNCED.
89 */
90 if ( ! defined( 'WP_FS__SKIP_EMAIL_ACTIVATION' ) ) {
91 define( 'WP_FS__SKIP_EMAIL_ACTIVATION', false );
92 }
93
94
95 #--------------------------------------------------------------------------------
96 #region Directories
97 #--------------------------------------------------------------------------------
98
99 if ( ! defined( 'WP_FS__DIR' ) ) {
100 define( 'WP_FS__DIR', dirname( __FILE__ ) );
101 }
102 if ( ! defined( 'WP_FS__DIR_INCLUDES' ) ) {
103 define( 'WP_FS__DIR_INCLUDES', WP_FS__DIR . '/includes' );
104 }
105 if ( ! defined( 'WP_FS__DIR_TEMPLATES' ) ) {
106 define( 'WP_FS__DIR_TEMPLATES', WP_FS__DIR . '/templates' );
107 }
108 if ( ! defined( 'WP_FS__DIR_ASSETS' ) ) {
109 define( 'WP_FS__DIR_ASSETS', WP_FS__DIR . '/assets' );
110 }
111 if ( ! defined( 'WP_FS__DIR_CSS' ) ) {
112 define( 'WP_FS__DIR_CSS', WP_FS__DIR_ASSETS . '/css' );
113 }
114 if ( ! defined( 'WP_FS__DIR_JS' ) ) {
115 define( 'WP_FS__DIR_JS', WP_FS__DIR_ASSETS . '/js' );
116 }
117 if ( ! defined( 'WP_FS__DIR_IMG' ) ) {
118 define( 'WP_FS__DIR_IMG', WP_FS__DIR_ASSETS . '/img' );
119 }
120 if ( ! defined( 'WP_FS__DIR_SDK' ) ) {
121 define( 'WP_FS__DIR_SDK', WP_FS__DIR_INCLUDES . '/sdk' );
122 }
123
124 #endregion
125
126 /**
127 * Domain / URL / Address
128 */
129 define( 'WP_FS__ROOT_DOMAIN_PRODUCTION', 'freemius.com' );
130 define( 'WP_FS__DOMAIN_PRODUCTION', 'wp.freemius.com' );
131 define( 'WP_FS__ADDRESS_PRODUCTION', 'https://' . WP_FS__DOMAIN_PRODUCTION );
132
133 if ( ! defined( 'WP_FS__DOMAIN_LOCALHOST' ) ) {
134 define( 'WP_FS__DOMAIN_LOCALHOST', 'wp.freemius' );
135 }
136 if ( ! defined( 'WP_FS__ADDRESS_LOCALHOST' ) ) {
137 define( 'WP_FS__ADDRESS_LOCALHOST', 'http://' . WP_FS__DOMAIN_LOCALHOST . ':8080' );
138 }
139
140 if ( ! defined( 'WP_FS__TESTING_DOMAIN' ) ) {
141 define( 'WP_FS__TESTING_DOMAIN', 'fswp' );
142 }
143
144 #--------------------------------------------------------------------------------
145 #region HTTP
146 #--------------------------------------------------------------------------------
147
148 if ( ! defined( 'WP_FS__IS_HTTP_REQUEST' ) ) {
149 define( 'WP_FS__IS_HTTP_REQUEST', isset( $_SERVER['HTTP_HOST'] ) && isset( $_SERVER['REQUEST_METHOD'] ) );
150 }
151
152 if ( ! defined( 'WP_FS__IS_HTTPS' ) ) {
153 define( 'WP_FS__IS_HTTPS', ( WP_FS__IS_HTTP_REQUEST &&
154 // Checks if CloudFlare's HTTPS (Flexible SSL support).
155 isset( $_SERVER['HTTP_X_FORWARDED_PROTO'] ) &&
156 'https' === strtolower( $_SERVER['HTTP_X_FORWARDED_PROTO'] )
157 ) ||
158 // Check if HTTPS request.
159 ( isset( $_SERVER['HTTPS'] ) && 'on' == $_SERVER['HTTPS'] ) ||
160 ( isset( $_SERVER['SERVER_PORT'] ) && 443 == $_SERVER['SERVER_PORT'] )
161 );
162 }
163
164 if ( ! defined( 'WP_FS__IS_POST_REQUEST' ) ) {
165 define( 'WP_FS__IS_POST_REQUEST', ( WP_FS__IS_HTTP_REQUEST &&
166 strtoupper( $_SERVER['REQUEST_METHOD'] ) == 'POST' ) );
167 }
168
169 if ( ! defined( 'WP_FS__REMOTE_ADDR' ) ) {
170 define( 'WP_FS__REMOTE_ADDR', fs_get_ip() );
171 }
172
173 if ( ! defined( 'WP_FS__IS_LOCALHOST' ) ) {
174 if ( defined( 'WP_FS__LOCALHOST_IP' ) ) {
175 define( 'WP_FS__IS_LOCALHOST', ( WP_FS__LOCALHOST_IP === WP_FS__REMOTE_ADDR ) );
176 } else {
177 define( 'WP_FS__IS_LOCALHOST', WP_FS__IS_HTTP_REQUEST &&
178 is_string( WP_FS__REMOTE_ADDR ) &&
179 ( substr( WP_FS__REMOTE_ADDR, 0, 4 ) === '127.' ||
180 WP_FS__REMOTE_ADDR === '::1' )
181 );
182 }
183 }
184
185 if ( ! defined( 'WP_FS__IS_LOCALHOST_FOR_SERVER' ) ) {
186 define( 'WP_FS__IS_LOCALHOST_FOR_SERVER', ( ! WP_FS__IS_HTTP_REQUEST ||
187 false !== strpos( $_SERVER['HTTP_HOST'], 'localhost' ) ) );
188 }
189
190 #endregion
191
192 if ( ! defined( 'WP_FS__IS_PRODUCTION_MODE' ) ) {
193 // By default, run with Freemius production servers.
194 define( 'WP_FS__IS_PRODUCTION_MODE', true );
195 }
196
197 if ( ! defined( 'WP_FS__ADDRESS' ) ) {
198 define( 'WP_FS__ADDRESS', ( WP_FS__IS_PRODUCTION_MODE ? WP_FS__ADDRESS_PRODUCTION : WP_FS__ADDRESS_LOCALHOST ) );
199 }
200
201
202 #--------------------------------------------------------------------------------
203 #region API
204 #--------------------------------------------------------------------------------
205
206 if ( ! defined( 'WP_FS__API_ADDRESS_LOCALHOST' ) ) {
207 define( 'WP_FS__API_ADDRESS_LOCALHOST', 'http://api.freemius-local.com:8080' );
208 }
209 if ( ! defined( 'WP_FS__API_SANDBOX_ADDRESS_LOCALHOST' ) ) {
210 define( 'WP_FS__API_SANDBOX_ADDRESS_LOCALHOST', 'http://sandbox-api.freemius:8080' );
211 }
212
213 // Set API address for local testing.
214 if ( ! WP_FS__IS_PRODUCTION_MODE ) {
215 if ( ! defined( 'FS_API__ADDRESS' ) ) {
216 define( 'FS_API__ADDRESS', WP_FS__API_ADDRESS_LOCALHOST );
217 }
218 if ( ! defined( 'FS_API__SANDBOX_ADDRESS' ) ) {
219 define( 'FS_API__SANDBOX_ADDRESS', WP_FS__API_SANDBOX_ADDRESS_LOCALHOST );
220 }
221 }
222
223 #endregion
224
225 #--------------------------------------------------------------------------------
226 #region Checkout
227 #--------------------------------------------------------------------------------
228
229 if ( ! defined( 'FS_CHECKOUT__ADDRESS_PRODUCTION' ) ) {
230 define( 'FS_CHECKOUT__ADDRESS_PRODUCTION', 'https://checkout.freemius.com' );
231 }
232
233 if ( ! defined( 'FS_CHECKOUT__ADDRESS_LOCALHOST' ) ) {
234 define( 'FS_CHECKOUT__ADDRESS_LOCALHOST', 'http://checkout.freemius-local.com:8080' );
235 }
236
237 if ( ! defined( 'FS_CHECKOUT__ADDRESS' ) ) {
238 define( 'FS_CHECKOUT__ADDRESS', ( WP_FS__IS_PRODUCTION_MODE ? FS_CHECKOUT__ADDRESS_PRODUCTION : FS_CHECKOUT__ADDRESS_LOCALHOST ) );
239 }
240
241 #endregion
242
243 define( 'WP_FS___OPTION_PREFIX', 'fs' . ( WP_FS__IS_PRODUCTION_MODE ? '' : '_dbg' ) . '_' );
244
245 if ( ! defined( 'WP_FS__ACCOUNTS_OPTION_NAME' ) ) {
246 define( 'WP_FS__ACCOUNTS_OPTION_NAME', WP_FS___OPTION_PREFIX . 'accounts' );
247 }
248 if ( ! defined( 'WP_FS__API_CACHE_OPTION_NAME' ) ) {
249 define( 'WP_FS__API_CACHE_OPTION_NAME', WP_FS___OPTION_PREFIX . 'api_cache' );
250 }
251 if ( ! defined( 'WP_FS__GDPR_OPTION_NAME' ) ) {
252 define( 'WP_FS__GDPR_OPTION_NAME', WP_FS___OPTION_PREFIX . 'gdpr' );
253 }
254 define( 'WP_FS__OPTIONS_OPTION_NAME', WP_FS___OPTION_PREFIX . 'options' );
255
256 /**
257 * Module types
258 *
259 * @since 1.2.2
260 */
261 define( 'WP_FS__MODULE_TYPE_PLUGIN', 'plugin' );
262 define( 'WP_FS__MODULE_TYPE_THEME', 'theme' );
263
264 /**
265 * Billing Frequencies
266 */
267 define( 'WP_FS__PERIOD_ANNUALLY', 'annual' );
268 define( 'WP_FS__PERIOD_MONTHLY', 'monthly' );
269 define( 'WP_FS__PERIOD_LIFETIME', 'lifetime' );
270
271 /**
272 * Plans
273 */
274 define( 'WP_FS__PLAN_DEFAULT_PAID', false );
275 define( 'WP_FS__PLAN_FREE', 'free' );
276 define( 'WP_FS__PLAN_TRIAL', 'trial' );
277
278 /**
279 * Times in seconds
280 */
281 if ( ! defined( 'WP_FS__TIME_5_MIN_IN_SEC' ) ) {
282 define( 'WP_FS__TIME_5_MIN_IN_SEC', 300 );
283 }
284 if ( ! defined( 'WP_FS__TIME_10_MIN_IN_SEC' ) ) {
285 define( 'WP_FS__TIME_10_MIN_IN_SEC', 600 );
286 }
287 // define( 'WP_FS__TIME_15_MIN_IN_SEC', 900 );
288 if ( ! defined( 'WP_FS__TIME_12_HOURS_IN_SEC' ) ) {
289 define( 'WP_FS__TIME_12_HOURS_IN_SEC', 43200 );
290 }
291 if ( ! defined( 'WP_FS__TIME_24_HOURS_IN_SEC' ) ) {
292 define( 'WP_FS__TIME_24_HOURS_IN_SEC', WP_FS__TIME_12_HOURS_IN_SEC * 2 );
293 }
294 if ( ! defined( 'WP_FS__TIME_WEEK_IN_SEC' ) ) {
295 define( 'WP_FS__TIME_WEEK_IN_SEC', 7 * WP_FS__TIME_24_HOURS_IN_SEC );
296 }
297
298 #--------------------------------------------------------------------------------
299 #region Debugging
300 #--------------------------------------------------------------------------------
301
302 if ( ! defined( 'WP_FS__DEBUG_SDK' ) ) {
303 $debug_mode = get_option( 'fs_debug_mode', null );
304
305 if ( $debug_mode === null ) {
306 $debug_mode = false;
307 add_option( 'fs_debug_mode', $debug_mode );
308 }
309
310 define( 'WP_FS__DEBUG_SDK', is_numeric( $debug_mode ) ? ( 0 < $debug_mode ) : WP_FS__DEV_MODE );
311 }
312
313 if ( ! defined( 'WP_FS__ECHO_DEBUG_SDK' ) ) {
314 define( 'WP_FS__ECHO_DEBUG_SDK', WP_FS__DEV_MODE && ! empty( $_GET['fs_dbg_echo'] ) );
315 }
316 if ( ! defined( 'WP_FS__LOG_DATETIME_FORMAT' ) ) {
317 define( 'WP_FS__LOG_DATETIME_FORMAT', 'Y-m-d H:i:s' );
318 }
319 if ( ! defined( 'FS_API__LOGGER_ON' ) ) {
320 define( 'FS_API__LOGGER_ON', WP_FS__DEBUG_SDK );
321 }
322
323 if ( WP_FS__ECHO_DEBUG_SDK ) {
324 error_reporting( E_ALL );
325 }
326
327 #endregion
328
329 if ( ! defined( 'WP_FS__SCRIPT_START_TIME' ) ) {
330 define( 'WP_FS__SCRIPT_START_TIME', time() );
331 }
332 if ( ! defined( 'WP_FS__DEFAULT_PRIORITY' ) ) {
333 define( 'WP_FS__DEFAULT_PRIORITY', 10 );
334 }
335 if ( ! defined( 'WP_FS__LOWEST_PRIORITY' ) ) {
336 define( 'WP_FS__LOWEST_PRIORITY', 999999999 );
337 }
338
339 #--------------------------------------------------------------------------------
340 #region Multisite Network
341 #--------------------------------------------------------------------------------
342
343 /**
344 * Do not use this define directly, it will have the wrong value
345 * during plugin uninstall/deletion when the inclusion of the plugin
346 * is triggered due to registration with register_uninstall_hook().
347 *
348 * Instead, use fs_is_network_admin().
349 *
350 * @author Vova Feldman (@svovaf)
351 */
352 if ( ! defined( 'WP_FS__IS_NETWORK_ADMIN' ) ) {
353 define( 'WP_FS__IS_NETWORK_ADMIN',
354 is_multisite() &&
355 ( is_network_admin() ||
356 ( ( defined( 'DOING_AJAX' ) && DOING_AJAX &&
357 ( isset( $_REQUEST['_fs_network_admin'] ) && 'true' === $_REQUEST['_fs_network_admin'] /*||
358 ( ! empty( $_REQUEST['action'] ) && 'delete-plugin' === $_REQUEST['action'] )*/ )
359 ) ||
360 // Plugin uninstall.
361 defined( 'WP_UNINSTALL_PLUGIN' ) )
362 )
363 );
364 }
365
366 /**
367 * Do not use this define directly, it will have the wrong value
368 * during plugin uninstall/deletion when the inclusion of the plugin
369 * is triggered due to registration with register_uninstall_hook().
370 *
371 * Instead, use fs_is_blog_admin().
372 *
373 * @author Vova Feldman (@svovaf)
374 */
375 if ( ! defined( 'WP_FS__IS_BLOG_ADMIN' ) ) {
376 define( 'WP_FS__IS_BLOG_ADMIN', is_blog_admin() || ( defined( 'DOING_AJAX' ) && DOING_AJAX && isset( $_REQUEST['_fs_blog_admin'] ) ) );
377 }
378
379 if ( ! defined( 'WP_FS__SHOW_NETWORK_EVEN_WHEN_DELEGATED' ) ) {
380 // Set to true to show network level settings even if delegated to site admins.
381 define( 'WP_FS__SHOW_NETWORK_EVEN_WHEN_DELEGATED', false );
382 }
383
384 #endregion
385
386 if ( ! defined( 'WP_FS__DEMO_MODE' ) ) {
387 define( 'WP_FS__DEMO_MODE', false );
388 }
389 if ( ! defined( 'FS_SDK__SSLVERIFY' ) ) {
390 define( 'FS_SDK__SSLVERIFY', false );
391 }
392