Changeset 2695668
- Timestamp:
- 03/18/2022 12:48:27 AM (4 years ago)
- Location:
- mobile-app-editor
- Files:
-
- 242 added
- 21 edited
-
tags/1.1.2 (added)
-
tags/1.1.2/admin (added)
-
tags/1.1.2/admin/class-wprne-admin.php (added)
-
tags/1.1.2/admin/index.php (added)
-
tags/1.1.2/assets (added)
-
tags/1.1.2/assets/css (added)
-
tags/1.1.2/assets/css/editor-main-style.css (added)
-
tags/1.1.2/assets/css/editor-style.css (added)
-
tags/1.1.2/assets/font (added)
-
tags/1.1.2/assets/font/LICENSE.txt (added)
-
tags/1.1.2/assets/font/OpenSans-Bold.ttf (added)
-
tags/1.1.2/assets/font/OpenSans-Regular.ttf (added)
-
tags/1.1.2/assets/font/OpenSans-SemiBold.ttf (added)
-
tags/1.1.2/assets/font/Qahiri-Regular.ttf (added)
-
tags/1.1.2/assets/fonts (added)
-
tags/1.1.2/assets/fonts/font-bold.ttf (added)
-
tags/1.1.2/assets/fonts/font-regular.ttf (added)
-
tags/1.1.2/assets/fonts/font-semibold.ttf (added)
-
tags/1.1.2/assets/js (added)
-
tags/1.1.2/assets/js/editor-display.js (added)
-
tags/1.1.2/assets/js/editor-main-script.js (added)
-
tags/1.1.2/assets/js/editor-runtime-script.js (added)
-
tags/1.1.2/assets/js/editor-script.js (added)
-
tags/1.1.2/assets/media (added)
-
tags/1.1.2/assets/media/FontAwesome.ttf (added)
-
tags/1.1.2/assets/media/MaterialIcons.ttf (added)
-
tags/1.1.2/assets/media/checkbcd1a436590360ed53ac2f46c76e43e4.bcd1a436.png (added)
-
tags/1.1.2/assets/media/placeholder.png (added)
-
tags/1.1.2/freemius (added)
-
tags/1.1.2/freemius/LICENSE.txt (added)
-
tags/1.1.2/freemius/README.md (added)
-
tags/1.1.2/freemius/assets (added)
-
tags/1.1.2/freemius/assets/css (added)
-
tags/1.1.2/freemius/assets/css/admin (added)
-
tags/1.1.2/freemius/assets/css/admin/account.css (added)
-
tags/1.1.2/freemius/assets/css/admin/add-ons.css (added)
-
tags/1.1.2/freemius/assets/css/admin/affiliation.css (added)
-
tags/1.1.2/freemius/assets/css/admin/checkout.css (added)
-
tags/1.1.2/freemius/assets/css/admin/common.css (added)
-
tags/1.1.2/freemius/assets/css/admin/connect.css (added)
-
tags/1.1.2/freemius/assets/css/admin/debug.css (added)
-
tags/1.1.2/freemius/assets/css/admin/dialog-boxes.css (added)
-
tags/1.1.2/freemius/assets/css/admin/gdpr-optin-notice.css (added)
-
tags/1.1.2/freemius/assets/css/admin/index.php (added)
-
tags/1.1.2/freemius/assets/css/admin/plugins.css (added)
-
tags/1.1.2/freemius/assets/css/customizer.css (added)
-
tags/1.1.2/freemius/assets/css/index.php (added)
-
tags/1.1.2/freemius/assets/img (added)
-
tags/1.1.2/freemius/assets/img/index.php (added)
-
tags/1.1.2/freemius/assets/img/mobile-app-builder.png (added)
-
tags/1.1.2/freemius/assets/img/mobile-app-editor.png (added)
-
tags/1.1.2/freemius/assets/img/plugin-icon.png (added)
-
tags/1.1.2/freemius/assets/img/theme-icon.png (added)
-
tags/1.1.2/freemius/assets/img/wp-app-builder.png (added)
-
tags/1.1.2/freemius/assets/index.php (added)
-
tags/1.1.2/freemius/assets/js (added)
-
tags/1.1.2/freemius/assets/js/index.php (added)
-
tags/1.1.2/freemius/assets/js/nojquery.ba-postmessage.js (added)
-
tags/1.1.2/freemius/assets/js/nojquery.ba-postmessage.min.js (added)
-
tags/1.1.2/freemius/assets/js/postmessage.js (added)
-
tags/1.1.2/freemius/config.php (added)
-
tags/1.1.2/freemius/includes (added)
-
tags/1.1.2/freemius/includes/class-freemius-abstract.php (added)
-
tags/1.1.2/freemius/includes/class-freemius.php (added)
-
tags/1.1.2/freemius/includes/class-fs-admin-notices.php (added)
-
tags/1.1.2/freemius/includes/class-fs-api.php (added)
-
tags/1.1.2/freemius/includes/class-fs-logger.php (added)
-
tags/1.1.2/freemius/includes/class-fs-options.php (added)
-
tags/1.1.2/freemius/includes/class-fs-plugin-updater.php (added)
-
tags/1.1.2/freemius/includes/class-fs-security.php (added)
-
tags/1.1.2/freemius/includes/class-fs-storage.php (added)
-
tags/1.1.2/freemius/includes/class-fs-user-lock.php (added)
-
tags/1.1.2/freemius/includes/customizer (added)
-
tags/1.1.2/freemius/includes/customizer/class-fs-customizer-support-section.php (added)
-
tags/1.1.2/freemius/includes/customizer/class-fs-customizer-upsell-control.php (added)
-
tags/1.1.2/freemius/includes/customizer/index.php (added)
-
tags/1.1.2/freemius/includes/debug (added)
-
tags/1.1.2/freemius/includes/debug/class-fs-debug-bar-panel.php (added)
-
tags/1.1.2/freemius/includes/debug/debug-bar-start.php (added)
-
tags/1.1.2/freemius/includes/debug/index.php (added)
-
tags/1.1.2/freemius/includes/entities (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-affiliate-terms.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-affiliate.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-billing.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-entity.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-payment.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-plugin-info.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-plugin-license.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-plugin-plan.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-plugin-tag.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-plugin.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-pricing.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-scope-entity.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-site.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-subscription.php (added)
-
tags/1.1.2/freemius/includes/entities/class-fs-user.php (added)
-
tags/1.1.2/freemius/includes/entities/index.php (added)
-
tags/1.1.2/freemius/includes/fs-core-functions.php (added)
-
tags/1.1.2/freemius/includes/fs-essential-functions.php (added)
-
tags/1.1.2/freemius/includes/fs-plugin-info-dialog.php (added)
-
tags/1.1.2/freemius/includes/i18n.php (added)
-
tags/1.1.2/freemius/includes/index.php (added)
-
tags/1.1.2/freemius/includes/l10n.php (added)
-
tags/1.1.2/freemius/includes/managers (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-admin-menu-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-admin-notice-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-cache-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-gdpr-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-key-value-storage.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-license-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-option-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-plan-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/class-fs-plugin-manager.php (added)
-
tags/1.1.2/freemius/includes/managers/index.php (added)
-
tags/1.1.2/freemius/includes/sdk (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/ArgumentNotExistException.php (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/EmptyArgumentException.php (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/Exception.php (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/InvalidArgumentException.php (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/OAuthException.php (added)
-
tags/1.1.2/freemius/includes/sdk/Exceptions/index.php (added)
-
tags/1.1.2/freemius/includes/sdk/FreemiusBase.php (added)
-
tags/1.1.2/freemius/includes/sdk/FreemiusWordPress.php (added)
-
tags/1.1.2/freemius/includes/sdk/LICENSE.txt (added)
-
tags/1.1.2/freemius/includes/sdk/index.php (added)
-
tags/1.1.2/freemius/includes/supplements (added)
-
tags/1.1.2/freemius/includes/supplements/fs-essential-functions-1.1.7.1.php (added)
-
tags/1.1.2/freemius/includes/supplements/fs-essential-functions-2.2.1.php (added)
-
tags/1.1.2/freemius/includes/supplements/index.php (added)
-
tags/1.1.2/freemius/index.php (added)
-
tags/1.1.2/freemius/languages (added)
-
tags/1.1.2/freemius/languages/freemius-cs_CZ.mo (added)
-
tags/1.1.2/freemius/languages/freemius-da_DK.mo (added)
-
tags/1.1.2/freemius/languages/freemius-en.mo (added)
-
tags/1.1.2/freemius/languages/freemius-es_ES.mo (added)
-
tags/1.1.2/freemius/languages/freemius-fr_FR.mo (added)
-
tags/1.1.2/freemius/languages/freemius-he_IL.mo (added)
-
tags/1.1.2/freemius/languages/freemius-hu_HU.mo (added)
-
tags/1.1.2/freemius/languages/freemius-it_IT.mo (added)
-
tags/1.1.2/freemius/languages/freemius-ja.mo (added)
-
tags/1.1.2/freemius/languages/freemius-nl_NL.mo (added)
-
tags/1.1.2/freemius/languages/freemius-ru_RU.mo (added)
-
tags/1.1.2/freemius/languages/freemius-ta.mo (added)
-
tags/1.1.2/freemius/languages/freemius-zh_CN.mo (added)
-
tags/1.1.2/freemius/languages/freemius.pot (added)
-
tags/1.1.2/freemius/languages/index.php (added)
-
tags/1.1.2/freemius/package.json (added)
-
tags/1.1.2/freemius/require.php (added)
-
tags/1.1.2/freemius/start.php (added)
-
tags/1.1.2/freemius/templates (added)
-
tags/1.1.2/freemius/templates/account (added)
-
tags/1.1.2/freemius/templates/account.php (added)
-
tags/1.1.2/freemius/templates/account/billing.php (added)
-
tags/1.1.2/freemius/templates/account/index.php (added)
-
tags/1.1.2/freemius/templates/account/partials (added)
-
tags/1.1.2/freemius/templates/account/partials/activate-license-button.php (added)
-
tags/1.1.2/freemius/templates/account/partials/addon.php (added)
-
tags/1.1.2/freemius/templates/account/partials/deactivate-license-button.php (added)
-
tags/1.1.2/freemius/templates/account/partials/index.php (added)
-
tags/1.1.2/freemius/templates/account/partials/site.php (added)
-
tags/1.1.2/freemius/templates/account/payments.php (added)
-
tags/1.1.2/freemius/templates/add-ons.php (added)
-
tags/1.1.2/freemius/templates/add-trial-to-pricing.php (added)
-
tags/1.1.2/freemius/templates/admin-notice.php (added)
-
tags/1.1.2/freemius/templates/ajax-loader.php (added)
-
tags/1.1.2/freemius/templates/auto-installation.php (added)
-
tags/1.1.2/freemius/templates/checkout.php (added)
-
tags/1.1.2/freemius/templates/connect.php (added)
-
tags/1.1.2/freemius/templates/contact.php (added)
-
tags/1.1.2/freemius/templates/debug (added)
-
tags/1.1.2/freemius/templates/debug.php (added)
-
tags/1.1.2/freemius/templates/debug/api-calls.php (added)
-
tags/1.1.2/freemius/templates/debug/index.php (added)
-
tags/1.1.2/freemius/templates/debug/logger.php (added)
-
tags/1.1.2/freemius/templates/debug/plugins-themes-sync.php (added)
-
tags/1.1.2/freemius/templates/debug/scheduled-crons.php (added)
-
tags/1.1.2/freemius/templates/email.php (added)
-
tags/1.1.2/freemius/templates/firewall-issues-js.php (added)
-
tags/1.1.2/freemius/templates/forms (added)
-
tags/1.1.2/freemius/templates/forms/affiliation.php (added)
-
tags/1.1.2/freemius/templates/forms/data-debug-mode.php (added)
-
tags/1.1.2/freemius/templates/forms/deactivation (added)
-
tags/1.1.2/freemius/templates/forms/deactivation/contact.php (added)
-
tags/1.1.2/freemius/templates/forms/deactivation/form.php (added)
-
tags/1.1.2/freemius/templates/forms/deactivation/index.php (added)
-
tags/1.1.2/freemius/templates/forms/deactivation/retry-skip.php (added)
-
tags/1.1.2/freemius/templates/forms/index.php (added)
-
tags/1.1.2/freemius/templates/forms/license-activation.php (added)
-
tags/1.1.2/freemius/templates/forms/optout.php (added)
-
tags/1.1.2/freemius/templates/forms/premium-versions-upgrade-handler.php (added)
-
tags/1.1.2/freemius/templates/forms/premium-versions-upgrade-metadata.php (added)
-
tags/1.1.2/freemius/templates/forms/resend-key.php (added)
-
tags/1.1.2/freemius/templates/forms/subscription-cancellation.php (added)
-
tags/1.1.2/freemius/templates/forms/trial-start.php (added)
-
tags/1.1.2/freemius/templates/forms/user-change.php (added)
-
tags/1.1.2/freemius/templates/gdpr-optin-js.php (added)
-
tags/1.1.2/freemius/templates/index.php (added)
-
tags/1.1.2/freemius/templates/js (added)
-
tags/1.1.2/freemius/templates/js/index.php (added)
-
tags/1.1.2/freemius/templates/js/jquery.content-change.php (added)
-
tags/1.1.2/freemius/templates/js/open-license-activation.php (added)
-
tags/1.1.2/freemius/templates/js/style-premium-theme.php (added)
-
tags/1.1.2/freemius/templates/partials (added)
-
tags/1.1.2/freemius/templates/partials/index.php (added)
-
tags/1.1.2/freemius/templates/partials/network-activation.php (added)
-
tags/1.1.2/freemius/templates/plugin-icon.php (added)
-
tags/1.1.2/freemius/templates/plugin-info (added)
-
tags/1.1.2/freemius/templates/plugin-info/description.php (added)
-
tags/1.1.2/freemius/templates/plugin-info/features.php (added)
-
tags/1.1.2/freemius/templates/plugin-info/index.php (added)
-
tags/1.1.2/freemius/templates/plugin-info/screenshots.php (added)
-
tags/1.1.2/freemius/templates/powered-by.php (added)
-
tags/1.1.2/freemius/templates/pricing.php (added)
-
tags/1.1.2/freemius/templates/secure-https-header.php (added)
-
tags/1.1.2/freemius/templates/sticky-admin-notice-js.php (added)
-
tags/1.1.2/freemius/templates/tabs-capture-js.php (added)
-
tags/1.1.2/freemius/templates/tabs.php (added)
-
tags/1.1.2/includes (added)
-
tags/1.1.2/includes/blank-template.php (added)
-
tags/1.1.2/includes/class-wprne-activator.php (added)
-
tags/1.1.2/includes/class-wprne-deactivator.php (added)
-
tags/1.1.2/includes/class-wprne-i18n.php (added)
-
tags/1.1.2/includes/class-wprne-loader.php (added)
-
tags/1.1.2/includes/class-wprne-page-templater.php (added)
-
tags/1.1.2/includes/class-wprne-rest-api.php (added)
-
tags/1.1.2/includes/class-wprne-woocommerce.php (added)
-
tags/1.1.2/includes/class-wprne.php (added)
-
tags/1.1.2/includes/index.php (added)
-
tags/1.1.2/index.php (added)
-
tags/1.1.2/languages (added)
-
tags/1.1.2/languages/mobile-app-editor.pot (added)
-
tags/1.1.2/license.txt (added)
-
tags/1.1.2/media (added)
-
tags/1.1.2/media/FontAwesome.ttf (added)
-
tags/1.1.2/media/MaterialIcons.ttf (added)
-
tags/1.1.2/media/checkbcd1a436590360ed53ac2f46c76e43e4.bcd1a436.png (added)
-
tags/1.1.2/media/placeholder.png (added)
-
tags/1.1.2/mobile-app-editor.php (added)
-
tags/1.1.2/readme.txt (added)
-
trunk/admin/class-wprne-admin.php (modified) (13 diffs)
-
trunk/freemius/README.md (added)
-
trunk/freemius/includes/class-freemius.php (modified) (4 diffs)
-
trunk/freemius/includes/managers/class-fs-admin-notice-manager.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/Exceptions/ArgumentNotExistException.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/Exceptions/EmptyArgumentException.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/Exceptions/Exception.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/Exceptions/InvalidArgumentException.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/Exceptions/OAuthException.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/FreemiusBase.php (modified) (1 diff)
-
trunk/freemius/includes/sdk/FreemiusWordPress.php (modified) (1 diff)
-
trunk/freemius/package.json (added)
-
trunk/freemius/require.php (modified) (1 diff)
-
trunk/freemius/start.php (modified) (1 diff)
-
trunk/freemius/templates/account/partials/addon.php (modified) (1 diff)
-
trunk/freemius/templates/ajax-loader.php (modified) (1 diff)
-
trunk/freemius/templates/debug.php (modified) (4 diffs)
-
trunk/freemius/templates/firewall-issues-js.php (modified) (2 diffs)
-
trunk/freemius/templates/partials/network-activation.php (modified) (1 diff)
-
trunk/freemius/templates/sticky-admin-notice-js.php (modified) (1 diff)
-
trunk/includes/class-wprne-rest-api.php (modified) (1 diff)
-
trunk/mobile-app-editor.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
mobile-app-editor/trunk/admin/class-wprne-admin.php
r2604033 r2695668 10 10 */ 11 11 // If this file is called directly, abort. 12 if ( !defined( 'ABSPATH' )) {12 if (!defined('ABSPATH')) { 13 13 exit; 14 14 } … … 31 31 * @var string $WPRNE The ID of this plugin. 32 32 */ 33 private $WPRNE ;33 private $WPRNE; 34 34 /** 35 35 * The version of this plugin. … … 39 39 * @var string $version The current version of this plugin. 40 40 */ 41 private $version ;41 private $version; 42 42 /** 43 43 * Initialize the class and set its properties. … … 47 47 * @param string $version The version of this plugin. 48 48 */ 49 public function __construct( $WPRNE, $version)49 public function __construct($WPRNE, $version) 50 50 { 51 51 $this->WPRNE = $WPRNE; 52 52 $this->version = $version; 53 53 } 54 54 55 55 /** 56 56 * Register the stylesheets for the admin area. … … 60 60 public function enqueue_styles() 61 61 { 62 $page = ( isset( $_GET['page'] ) ? sanitize_text_field( $_GET['page'] ) : "");63 if ( empty($page) || $page !== 'app-editor') {62 $page = (isset($_GET['page']) ? sanitize_text_field($_GET['page']) : ""); 63 if (empty($page) || $page !== 'app-editor') { 64 64 return; 65 65 } … … 79 79 ); 80 80 } 81 81 82 82 /** 83 83 * Register the JavaScript for the admin area. … … 87 87 public function enqueue_scripts() 88 88 { 89 global $wprne_fs ;90 if ( $wprne_fs->is_activation_mode()) {89 global $wprne_fs; 90 if ($wprne_fs->is_activation_mode()) { 91 91 return; 92 92 } 93 $page = ( isset( $_GET['page'] ) ? sanitize_text_field( $_GET['page'] ) : "");94 if ( empty($page) || $page !== 'app-editor') {93 $page = (isset($_GET['page']) ? sanitize_text_field($_GET['page']) : ""); 94 if (empty($page) || $page !== 'app-editor') { 95 95 return; 96 96 } … … 119 119 'editor-display-script', 120 120 WPRNE_PLUGIN_URL . '/assets/js/editor-display.js', 121 array( "jquery"),121 array("jquery"), 122 122 $this->version, 123 123 true 124 124 ); 125 $settings = get_option( 'wprne_settings', array());126 $woock = ( !empty($settings['woock']) ? $settings['woock'] : '');127 $woocs = ( !empty($settings['woocs']) ? $settings['woocs'] : '');125 $settings = get_option('wprne_settings', array()); 126 $woock = (!empty($settings['woock']) ? $settings['woock'] : ''); 127 $woocs = (!empty($settings['woocs']) ? $settings['woocs'] : ''); 128 128 $localize_data = array( 129 'baseUrl' => home_url( '/'),129 'baseUrl' => home_url('/'), 130 130 'pluginUrl' => WPRNE_PLUGIN_URL, 131 131 'translate' => self::get_translate(), 132 132 'ck' => $woock, 133 133 'cs' => $woocs, 134 'nonce' => wp_create_nonce( 'wp_rest'),134 'nonce' => wp_create_nonce('wp_rest'), 135 135 'upgradeUrl' => wprne_fs()->get_upgrade_url(), 136 136 ); 137 wp_localize_script( 'editor-script', 'wprneLocalize', $localize_data ); 138 } 139 137 138 if (wprne_fs()->is__premium_only()) { 139 $localize_data = array_merge($localize_data, array('pro' => wprne_fs()->can_use_premium_code())); 140 } 141 142 wp_localize_script('editor-script', 'wprneLocalize', $localize_data); 143 } 144 140 145 /** 141 146 * Admin menu … … 147 152 add_menu_page( 148 153 'app-editor', 149 __( 'Mobile App Editor', 'wprne'),154 __('Mobile App Editor', 'wprne'), 150 155 'edit_others_posts', 151 156 'app-editor', 152 array( $this, 'wprne_menu_page'),157 array($this, 'wprne_menu_page'), 153 158 'dashicons-smartphone', 154 159 50 155 160 ); 156 161 } 157 162 158 163 /** 159 164 * Publish post … … 161 166 * @since 1.0.0 162 167 */ 163 public function publish_post( $ID, $post)168 public function publish_post($ID, $post) 164 169 { 165 170 $post_id = $post->ID; 166 $push_notif_sent = get_post_meta( $post_id, 'wprne_push_notif_sent', true ); 167 $is_send_push = get_option( "wprne_send_post_pushnotif" ); 168 169 if ( $is_send_push && empty($push_notif_sent) && !wp_is_post_revision( $post_id ) ) { 170 $tokens = get_option( 'wprne_push_notif_token', array() ); 171 $title = get_the_title( $post_id ); 172 $urlparts = parse_url( get_site_url() ); 173 $domain = $urlparts["host"]; 174 $body = []; 175 foreach ( $tokens as $token => $value ) { 176 if ( $value ) { 177 $body[] = [ 178 'to' => $token, 179 'sound' => 'default', 180 'title' => $domain, 181 'body' => $title, 182 'priority' => 'high', 183 ]; 184 } 171 $push_notif_sent = get_post_meta($post_id, 'wprne_push_notif_sent', true); 172 $is_send_push = get_option("wprne_send_post_pushnotif"); 173 if ($is_send_push && empty($push_notif_sent) && !wp_is_post_revision($post_id)) { 174 $tokens = get_option('wprne_push_notif_token', array()); 175 $title = get_the_title($post_id); 176 $urlparts = parse_url(get_site_url()); 177 $domain = $urlparts["host"]; 178 $body = []; 179 foreach ($tokens as $token => $value) { 180 if($value){ 181 $body[] = [ 182 'to' => $token, 183 'sound' => 'default', 184 'title' => $domain, 185 'body' => $title, 186 'priority' => 'high', 187 ]; 188 } 185 189 } 186 $endpoint = 'https://exp.host/--/api/v2/push/send'; 187 $body = wp_json_encode( $body ); 188 $options = [ 189 'body' => $body, 190 'headers' => [ 191 'Content-Type' => 'application/json', 192 ], 193 'timeout' => 60, 194 'redirection' => 5, 195 'blocking' => true, 196 'httpversion' => '1.0', 197 'sslverify' => false, 198 'data_format' => 'body', 199 ]; 200 $response = wp_remote_post( $endpoint, $options ); 201 update_post_meta( $post_id, 'wprne_push_notif_sent', true ); 190 $endpoint = 'https://exp.host/--/api/v2/push/send'; 191 192 $body = wp_json_encode($body); 193 194 $options = [ 195 'body' => $body, 196 'headers' => [ 197 'Content-Type' => 'application/json', 198 ], 199 'timeout' => 60, 200 'redirection' => 5, 201 'blocking' => true, 202 'httpversion' => '1.0', 203 'sslverify' => false, 204 'data_format' => 'body', 205 ]; 206 207 $response = wp_remote_post($endpoint, $options); 208 209 update_post_meta($post_id, 'wprne_push_notif_sent', true); 202 210 } 203 204 } 205 211 } 212 206 213 /** 207 214 * Admin menu callback … … 211 218 public function wprne_menu_page() 212 219 { 213 ?>220 ?> 214 221 <style> 215 222 #wpbody-content { … … 222 229 @font-face { 223 230 font-family: 'MaterialIcons'; 224 src: url(<?php 225 echo esc_url( WPRNE_PLUGIN_URL . '/assets/media/MaterialIcons.ttf' );226 ?>) format('truetype');231 src: url(<?php 232 echo esc_url(WPRNE_PLUGIN_URL . '/assets/media/MaterialIcons.ttf'); 233 ?>) format('truetype'); 227 234 } 228 235 229 236 @font-face { 230 237 font-family: 'FontAwesome'; 231 src: url(<?php 232 echo esc_url( WPRNE_PLUGIN_URL . '/assets/media/FontAwesome.ttf' );233 ?>) format('truetype');238 src: url(<?php 239 echo esc_url(WPRNE_PLUGIN_URL . '/assets/media/FontAwesome.ttf'); 240 ?>) format('truetype'); 234 241 } 235 242 </style> 236 243 </div> 237 <?php 238 } 239 244 <?php 245 } 246 240 247 /** 241 248 * Get all translatable word for script localize data. … … 246 253 { 247 254 return array( 248 'pluginTitle' => __( 'Mobile App Editor', 'wprne' ), 249 'apps' => __( 'Apps', 'wprne' ), 250 'newApp' => __( 'New App', 'wprne' ), 251 'editApp' => __( 'Edit app', 'wprne' ), 252 'deleteApp' => __( 'Delete app', 'wprne' ), 253 'newAppTemplate' => __( 'Create new app using this template', 'wprne' ), 254 'createNewApp' => __( 'Create New App', 'wprne' ), 255 'appName' => __( 'App name', 'wprne' ), 256 'deleteAppConfirm' => __( 'Are you sure to delete', 'wprne' ), 257 'errorNewApp' => __( 'Something went wrong trying to create new app"', 'wprne' ), 258 'title' => __( 'Title', 'wprne' ), 259 'buttonType' => __( 'Button Type', 'wprne' ), 260 'font' => __( 'Font', 'wprne' ), 261 'icon' => __( 'Icon', 'wprne' ), 262 'fontSize' => __( 'Font Size', 'wprne' ), 263 'fontColor' => __( 'Font Color', 'wprne' ), 264 'iconSize' => __( 'Icon Size', 'wprne' ), 265 'iconColor' => __( 'Icon Color', 'wprne' ), 266 'onPressAction' => __( 'On Press Action', 'wprne' ), 267 'autoplay' => __( 'Autoplay', 'wprne' ), 268 'autoplayHint' => __( 'Autoplay always disabled in builder mode', 'wprne' ), 269 'dot' => __( 'Dot', 'wprne' ), 270 'dotHint' => __( 'Dot always enabled in builder mode', 'wprne' ), 271 'enable' => __( 'Enable', 'wprne' ), 272 'delay' => __( 'Delay (second)', 'wprne' ), 273 'activeColor' => __( 'Active Color', 'wprne' ), 274 'productPreview' => __( 'Product Preview', 'wprne' ), 275 'addToCart' => __( 'Add to Cart', 'wprne' ), 276 'direction' => __( 'Direction', 'wprne' ), 277 'justify' => __( 'Justify Content', 'wprne' ), 278 'justifyHint' => __( 'Align items along the main axis of their container', 'wprne' ), 279 'alignItems' => __( 'Align Items', 'wprne' ), 280 'alignItemsHint' => __( 'Align items along the cross axis of their container', 'wprne' ), 281 'scrollable' => __( 'Scrollable', 'wprne' ), 282 'itemDirection' => __( 'Item Direction', 'wprne' ), 283 'showScroll' => __( 'Show Scroll', 'wprne' ), 284 'numColumns' => __( 'Number of Column', 'wprne' ), 285 'postType' => __( 'Post Type', 'wprne' ), 286 'postsCount' => __( 'Posts Count', 'wprne' ), 287 'category' => __( 'Category', 'wprne' ), 288 'order' => __( 'Order', 'wprne' ), 289 'orderby' => __( 'Order By', 'wprne' ), 290 'keyword' => __( 'Keyword', 'wprne' ), 291 'postQuery' => __( 'Post Query', 'wprne' ), 292 'changePostQuery' => __( 'Change Post Query', 'wprne' ), 293 'bestSeller ' => __( 'Best Seller', 'wprne' ), 294 'featured' => __( 'Featured', 'wprne' ), 295 'onSale' => __( 'On Sale', 'wprne' ), 296 'changeProductQuery' => __( 'Change Product Query', 'wprne' ), 297 'source' => __( 'Source', 'wprne' ), 298 'postContent' => __( 'Post Content', 'wprne' ), 299 'resizeMode' => __( 'Resize Mode', 'wprne' ), 300 'carouselSize' => __( 'Carousel Size', 'wprne' ), 301 'carouselSizeHint' => __( 'Use fixed number or % (ex: 32, 50%)', 'wprne' ), 302 'width' => __( 'Width', 'wprne' ), 303 'height' => __( 'Height', 'wprne' ), 304 'postPreview' => __( 'Post Preview', 'wprne' ), 305 'contentType' => __( 'Content Type', 'wprne' ), 306 'staticContent' => __( 'Static Content', 'wprne' ), 307 'htmlContent' => __( 'Html Content', 'wprne' ), 308 'asWebView' => __( 'As Web View', 'wprne' ), 309 'charLength' => __( 'Character Length', 'wprne' ), 310 'fontStyle' => __( 'Font Style', 'wprne' ), 311 'fontWeight' => __( 'Font Weight', 'wprne' ), 312 'textAlign' => __( 'Text Align', 'wprne' ), 313 'textTransform' => __( 'Text Transform', 'wprne' ), 314 'lineHeight' => __( 'Line Height', 'wprne' ), 315 'videoId' => __( 'Video ID', 'wprne' ), 316 'insertComponent' => __( 'Insert selected component', 'wprne' ), 317 'container' => __( 'Container', 'wprne' ), 318 'button' => __( 'Button', 'wprne' ), 319 'text' => __( 'Text', 'wprne' ), 320 'image' => __( 'Image', 'wprne' ), 321 'carousel' => __( 'Carousel', 'wprne' ), 322 'gridPost' => __( 'Grid Post', 'wprne' ), 323 'allComponents' => __( 'All Components', 'wprne' ), 324 'moveUp"' => __( 'move up', 'wprne' ), 325 'moveDown' => __( 'move down', 'wprne' ), 326 'duplicate' => __( 'duplicate', 'wprne' ), 327 'delete' => __( 'delete', 'wprne' ), 328 'cut' => __( 'cut', 'wprne' ), 329 'copy' => __( 'copy', 'wprne' ), 330 'paste' => __( 'paste', 'wprne' ), 331 'saveToTemplate' => __( 'save template', 'wprne' ), 332 'saveTemplate' => __( 'Save Template', 'wprne' ), 333 'movedUpWarning' => __( 'This component can\'t be moved up', 'wprne' ), 334 'movedDownWarning' => __( 'This component can\'t be moved down', 'wprne' ), 335 'deletedWarning' => __( 'This component can\'t be deleted', 'wprne' ), 336 'duplicatedwarning' => __( 'This component can\'t be duplicated', 'wprne' ), 337 'savedWarning' => __( 'This component can\'t be saved', 'wprne' ), 338 'cutWarning' => __( 'This component can\'t be cut', 'wprne' ), 339 'copiedWarning' => __( 'This component can\'t be copied', 'wprne' ), 340 'pastedWarning' => __( 'Component can only be inserted to a container', 'wprne' ), 341 'alertSettingsTitle' => __( 'Click on a component in builder mode to edit it\'s properties', 'wprne' ), 342 'alertSettingsText' => __( 'You could also select component from layers panel', 'wprne' ), 343 'flex' => __( 'Flex', 'wprne' ), 344 'flexHint' => __( 'Flex will define how your items are going to “fill” over the available space along your main axis. Space will be divided according to each element\'s flex property.', 'wprne' ), 345 'size' => __( 'Size', 'wprne' ), 346 'sizeHint' => __( 'Use auto, fixed number or % (ex: 32, 50%)', 'wprne' ), 347 'backgroundColor' => __( 'Background Color', 'wprne' ), 348 'colorHint' => __( 'Use color name, hex format or rgba format (ex: black, red, #FFF, rgba(0,0,0,1))', 'wprne' ), 349 'dynamicColor' => __( 'Dynamic Background Color', 'wprne' ), 350 'margin' => __( 'Margin', 'wprne' ), 351 'marginHint' => __( 'Use auto, fixed number or % (ex: 16, 10%)', 'wprne' ), 352 'padding' => __( 'Padding', 'wprne' ), 353 'position' => __( 'Position', 'wprne' ), 354 'borderRadius' => __( 'Border Radius', 'wprne' ), 355 'border' => __( 'Border', 'wprne' ), 356 'buildApk' => __( 'Build APK', 'wprne' ), 357 'build' => __( 'Build', 'wprne' ), 358 'close' => __( 'Close', 'wprne' ), 359 'refresh' => __( 'Refresh', 'wprne' ), 360 'inputImage' => __( "Drag 'n' drop some files here, or click to select files", 'wprne' ), 361 'githubToken' => __( 'Github token', 'wprne' ), 362 'expoUser' => __( 'Expo user name', 'wprne' ), 363 'expoPassword' => __( 'Expo password', 'wprne' ), 364 'appName' => __( 'App name', 'wprne' ), 365 'appSlug' => __( 'App slug', 'wprne' ), 366 'appPackage' => __( 'App package', 'wprne' ), 367 'appVersion' => __( 'App version', 'wprne' ), 368 'androidVersioCode' => __( 'App version number', 'wprne' ), 369 'appIcon' => __( 'App icon (png 1024 x 1024)', 'wprne' ), 370 'splashImage' => __( 'Splash screen image (png)', 'wprne' ), 371 'repoCreated' => __( 'The repository has been created', 'wprne' ), 372 'buildRun' => __( 'Build process is running', 'wprne' ), 373 'githubActionError' => __( 'Github actions not found', 'wprne' ), 374 'buildError' => __( 'There is an error, build process stopped', 'wprne' ), 375 'checkRepo' => __( 'Create the repository on github', 'wprne' ), 376 'minimize' => __( 'Minimize', 'wprne' ), 377 'fullscreen' => __( 'Fullscreen', 'wprne' ), 378 'undo' => __( 'Undo', 'wprne' ), 379 'redo' => __( 'Redo', 'wprne' ), 380 'saveSettings' => __( 'Save Settings', 'wprne' ), 381 'woock' => __( 'Woocommerce API Consumer Key', 'wprne' ), 382 'woocs' => __( 'Woocommerce API Consumer Secret', 'wprne' ), 383 'settings' => __( 'Settings', 'wprne' ), 384 'deleteConfirm' => __( 'Are You sure to delete this template?', 'wprne' ), 385 'insertTemplate' => __( 'insert template', 'wprne' ), 386 'deleteTemplate' => __( 'delete template', 'wprne' ), 387 'deleteTemplateHeader' => __( 'Delete Template', 'wprne' ), 388 'save' => __( 'Save', 'wprne' ), 389 'pageName' => __( 'Page Name', 'wprne' ), 390 'pageTemplates' => __( 'Page Templates', 'wprne' ), 391 'showHeaderBar' => __( 'Show Header Bar', 'wprne' ), 392 'addBottomTab' => __( 'Add to Bottom Tab Navigation', 'wprne' ), 393 'priority' => __( 'Priority', 'wprne' ), 394 'inactiveColor' => __( 'Inactive Color', 'wprne' ), 395 'addNewPage' => __( 'add new page', 'wprne' ), 396 'addPageDialog' => __( 'Add New Page', 'wprne' ), 397 'deletePageDialog' => __( 'Delete Page', 'wprne' ), 398 'deletePage' => __( 'delete page', 'wprne' ), 399 'duplicatePage' => __( 'duplicate selected page', 'wprne' ), 400 'pageName' => __( 'Page Name', 'wprne' ), 401 'selectedPageSetting' => __( 'selected page settings', 'wprne' ), 402 'toolbarAlert' => __( 'There is no page. Add a new page from the pages panel on the left.', 'wprne' ), 403 'errorSavePages' => __( 'Something went wrong trying to save pages', 'wprne' ), 404 'successSavePages' => __( 'Pages has been saved', 'wprne' ), 405 'previewMode' => __( 'Preview Mode', 'wprne' ), 406 'builderMode' => __( 'Builder Mode', 'wprne' ), 407 'layers' => __( 'Layers', 'wprne' ), 408 'pages' => __( 'Pages', 'wprne' ), 409 'templates' => __( 'Templates', 'wprne' ), 410 'layerPanelAlert' => __( 'Layers panel only available in builder mode', 'wprne' ), 411 'templatePanelAlert' => __( 'Templates panel only available in builder mode', 'wprne' ), 412 'savePages' => __( 'Save Pages', 'wprne' ), 413 'saving' => __( 'Saving...', 'wprne' ), 414 'move' => __( 'move', 'wprne' ), 415 'horizontal' => __( 'Horizontal', 'wprne' ), 416 'vertical' => __( 'Vertical', 'wprne' ), 417 'solid' => __( 'Solid', 'wprne' ), 418 'clear' => __( 'Clear', 'wprne' ), 419 'outline' => __( 'Outline', 'wprne' ), 420 'navigate' => __( 'navigate', 'wprne' ), 421 'goBack' => __( 'go back', 'wprne' ), 422 'atcAction' => __( 'add to cart', 'wprne' ), 423 'toCheckout' => __( 'to checkout', 'wprne' ), 424 'addQty' => __( 'add cart item quantity', 'wprne' ), 425 'reduceQty' => __( 'reduce cart item quantity', 'wprne' ), 426 'yes' => __( 'Yes', 'wprne' ), 427 'no' => __( 'No', 'wprne' ), 428 'wooProducts' => __( 'Woocommerce Products', 'wprne' ), 429 'wooOrders' => __( 'Woocommerce Orders', 'wprne' ), 430 'descending' => __( 'Descending', 'wprne' ), 431 'ascending' => __( 'Ascending', 'wprne' ), 432 'date' => __( 'Date', 'wprne' ), 433 'postId' => __( 'Post Id', 'wprne' ), 434 'modified' => __( 'Modified', 'wprne' ), 435 'all' => __( 'All', 'wprne' ), 436 'selectImage' => __( 'Select image', 'wprne' ), 437 'changeImage' => __( 'Change image', 'wprne' ), 438 'postImage' => __( 'Post featured image', 'wprne' ), 439 'static' => __( 'static', 'wprne' ), 440 'orderId' => __( 'order number', 'wprne' ), 441 'orderStatus' => __( 'order status', 'wprne' ), 442 'orderItem' => __( 'order item', 'wprne' ), 443 'orderTotal' => __( 'order total', 'wprne' ), 444 'shippingTotal' => __( 'shipping total', 'wprne' ), 445 'paymentMethod' => __( 'payment method', 'wprne' ), 446 'totalTax' => __( 'total tax', 'wprne' ), 447 'currencySymbol' => __( 'currency symbol', 'wprne' ), 448 'excerpt' => __( 'Excerpt', 'wprne' ), 449 'content' => __( 'Content', 'wprne' ), 450 'singlePost' => __( 'Single Post', 'wprne' ), 451 'searchPost' => __( 'Search Post', 'wprne' ), 452 'wooSingleProduct' => __( 'Woocommerce Single Product', 'wprne' ), 453 'wooImageCarousel' => __( 'Product Image Carousel', 'wprne' ), 454 'wooCart' => __( 'Woocommerce Cart', 'wprne' ), 455 'cartItem' => __( 'Cart Item', 'wprne' ), 456 'checkoutNative' => __( 'Woocommerce Checkout', 'wprne' ), 457 'checkoutWebView' => __( 'Checkout Web View', 'wprne' ), 458 'youtubePlayer' => __( 'Youtube Player', 'wprne' ), 459 'selectComponent' => __( 'Select Component', 'wprne' ), 460 'relative' => __( 'Relative', 'wprne' ), 461 'absolute' => __( 'Absolute', 'wprne' ), 462 'blank' => __( 'Blank', 'wprne' ), 463 'wooShop' => __( 'Woocommerce Shop', 'wprne' ), 464 'singleProduct' => __( 'Single Product', 'wprne' ), 465 'myOrder' => __( 'My Order', 'wprne' ), 466 'searchProduct' => __( 'Search Product', 'wprne' ), 467 'addTemplateError' => __( 'Something went wrong trying to save template', 'wprne' ), 468 'addTemplateSuccess' => __( 'Template has been saved', 'wprne' ), 469 'saveSettingsError' => __( 'Something went wrong trying to save settings', 'wprne' ), 470 'saveSettingsSuccess' => __( 'Settings has been saved', 'wprne' ), 471 'tutorials' => __( 'Tutorials', 'wprne' ), 472 ); 473 } 474 255 'pluginTitle' => __('Mobile App Editor', 'wprne'), 256 'apps' => __('Apps', 'wprne'), 257 'newApp' => __('New App', 'wprne'), 258 'editApp' => __('Edit app', 'wprne'), 259 'deleteApp' => __('Delete app', 'wprne'), 260 'newAppTemplate' => __('Create new app using this template', 'wprne'), 261 'createNewApp' => __('Create New App', 'wprne'), 262 'appName' => __('App name', 'wprne'), 263 'deleteAppConfirm' => __('Are you sure to delete', 'wprne'), 264 'errorNewApp' => __('Something went wrong trying to create new app"', 'wprne'), 265 'title' => __('Title', 'wprne'), 266 'buttonType' => __('Button Type', 'wprne'), 267 'font' => __('Font', 'wprne'), 268 'icon' => __('Icon', 'wprne'), 269 'fontSize' => __('Font Size', 'wprne'), 270 'fontColor' => __('Font Color', 'wprne'), 271 'iconSize' => __('Icon Size', 'wprne'), 272 'iconColor' => __('Icon Color', 'wprne'), 273 'onPressAction' => __('On Press Action', 'wprne'), 274 'autoplay' => __('Autoplay', 'wprne'), 275 'autoplayHint' => __('Autoplay always disabled in builder mode', 'wprne'), 276 'dot' => __('Dot', 'wprne'), 277 'dotHint' => __('Dot always enabled in builder mode', 'wprne'), 278 'enable' => __('Enable', 'wprne'), 279 'delay' => __('Delay (second)', 'wprne'), 280 'activeColor' => __('Active Color', 'wprne'), 281 'productPreview' => __('Product Preview', 'wprne'), 282 'addToCart' => __('Add to Cart', 'wprne'), 283 'direction' => __('Direction', 'wprne'), 284 'justify' => __('Justify Content', 'wprne'), 285 'justifyHint' => __('Align items along the main axis of their container', 'wprne'), 286 'alignItems' => __('Align Items', 'wprne'), 287 'alignItemsHint' => __('Align items along the cross axis of their container', 'wprne'), 288 'scrollable' => __('Scrollable', 'wprne'), 289 'itemDirection' => __('Item Direction', 'wprne'), 290 'showScroll' => __('Show Scroll', 'wprne'), 291 'numColumns' => __('Number of Column', 'wprne'), 292 'postType' => __('Post Type', 'wprne'), 293 'postsCount' => __('Posts Count', 'wprne'), 294 'category' => __('Category', 'wprne'), 295 'order' => __('Order', 'wprne'), 296 'orderby' => __('Order By', 'wprne'), 297 'keyword' => __('Keyword', 'wprne'), 298 'postQuery' => __('Post Query', 'wprne'), 299 'changePostQuery' => __('Change Post Query', 'wprne'), 300 'bestSeller ' => __('Best Seller', 'wprne'), 301 'featured' => __('Featured', 'wprne'), 302 'onSale' => __('On Sale', 'wprne'), 303 'changeProductQuery' => __('Change Product Query', 'wprne'), 304 'source' => __('Source', 'wprne'), 305 'postContent' => __('Post Content', 'wprne'), 306 'resizeMode' => __('Resize Mode', 'wprne'), 307 'carouselSize' => __('Carousel Size', 'wprne'), 308 'carouselSizeHint' => __('Use fixed number or % (ex: 32, 50%)', 'wprne'), 309 'width' => __('Width', 'wprne'), 310 'height' => __('Height', 'wprne'), 311 'postPreview' => __('Post Preview', 'wprne'), 312 'contentType' => __('Content Type', 'wprne'), 313 'staticContent' => __('Static Content', 'wprne'), 314 'htmlContent' => __('Html Content', 'wprne'), 315 'asWebView' => __('As Web View', 'wprne'), 316 'charLength' => __('Character Length', 'wprne'), 317 'fontStyle' => __('Font Style', 'wprne'), 318 'fontWeight' => __('Font Weight', 'wprne'), 319 'textAlign' => __('Text Align', 'wprne'), 320 'textTransform' => __('Text Transform', 'wprne'), 321 'lineHeight' => __('Line Height', 'wprne'), 322 'videoId' => __('Video ID', 'wprne'), 323 'insertComponent' => __('Insert selected component', 'wprne'), 324 'container' => __('Container', 'wprne'), 325 'button' => __('Button', 'wprne'), 326 'text' => __('Text', 'wprne'), 327 'image' => __('Image', 'wprne'), 328 'carousel' => __('Carousel', 'wprne'), 329 'gridPost' => __('Grid Post', 'wprne'), 330 'allComponents' => __('All Components', 'wprne'), 331 'moveUp"' => __('move up', 'wprne'), 332 'moveDown' => __('move down', 'wprne'), 333 'duplicate' => __('duplicate', 'wprne'), 334 'delete' => __('delete', 'wprne'), 335 'cut' => __('cut', 'wprne'), 336 'copy' => __('copy', 'wprne'), 337 'paste' => __('paste', 'wprne'), 338 'saveToTemplate' => __('save template', 'wprne'), 339 'saveTemplate' => __('Save Template', 'wprne'), 340 'movedUpWarning' => __('This component can\'t be moved up', 'wprne'), 341 'movedDownWarning' => __('This component can\'t be moved down', 'wprne'), 342 'deletedWarning' => __('This component can\'t be deleted', 'wprne'), 343 'duplicatedwarning' => __('This component can\'t be duplicated', 'wprne'), 344 'savedWarning' => __('This component can\'t be saved', 'wprne'), 345 'cutWarning' => __('This component can\'t be cut', 'wprne'), 346 'copiedWarning' => __('This component can\'t be copied', 'wprne'), 347 'pastedWarning' => __('Component can only be inserted to a container', 'wprne'), 348 'alertSettingsTitle' => __('Click on a component in builder mode to edit it\'s properties', 'wprne'), 349 'alertSettingsText' => __('You could also select component from layers panel', 'wprne'), 350 'flex' => __('Flex', 'wprne'), 351 'flexHint' => __('Flex will define how your items are going to “fill” over the available space along your main axis. Space will be divided according to each element\'s flex property.', 'wprne'), 352 'size' => __('Size', 'wprne'), 353 'sizeHint' => __('Use auto, fixed number or % (ex: 32, 50%)', 'wprne'), 354 'backgroundColor' => __('Background Color', 'wprne'), 355 'colorHint' => __('Use color name, hex format or rgba format (ex: black, red, #FFF, rgba(0,0,0,1))', 'wprne'), 356 'dynamicColor' => __('Dynamic Background Color', 'wprne'), 357 'margin' => __('Margin', 'wprne'), 358 'marginHint' => __('Use auto, fixed number or % (ex: 16, 10%)', 'wprne'), 359 'padding' => __('Padding', 'wprne'), 360 'position' => __('Position', 'wprne'), 361 'borderRadius' => __('Border Radius', 'wprne'), 362 'border' => __('Border', 'wprne'), 363 'buildApk' => __('Build APK', 'wprne'), 364 'build' => __('Build', 'wprne'), 365 'close' => __('Close', 'wprne'), 366 'refresh' => __('Refresh', 'wprne'), 367 'inputImage' => __("Drag 'n' drop some files here, or click to select files", 'wprne'), 368 'githubToken' => __('Github token', 'wprne'), 369 'expoUser' => __('Expo user name', 'wprne'), 370 'expoPassword' => __('Expo password', 'wprne'), 371 'appName' => __('App name', 'wprne'), 372 'appSlug' => __('App slug', 'wprne'), 373 'appPackage' => __('App package', 'wprne'), 374 'appVersion' => __('App version', 'wprne'), 375 'androidVersioCode' => __('App version number', 'wprne'), 376 'appIcon' => __('App icon (png 1024 x 1024)', 'wprne'), 377 'splashImage' => __('Splash screen image (png)', 'wprne'), 378 'repoCreated' => __('The repository has been created', 'wprne'), 379 'buildRun' => __('Build process is running', 'wprne'), 380 'githubActionError' => __('Github actions not found', 'wprne'), 381 'buildError' => __('There is an error, build process stopped', 'wprne'), 382 'checkRepo' => __('Create the repository on github', 'wprne'), 383 'minimize' => __('Minimize', 'wprne'), 384 'fullscreen' => __('Fullscreen', 'wprne'), 385 'undo' => __('Undo', 'wprne'), 386 'redo' => __('Redo', 'wprne'), 387 'saveSettings' => __('Save Settings', 'wprne'), 388 'woock' => __('Woocommerce API Consumer Key', 'wprne'), 389 'woocs' => __('Woocommerce API Consumer Secret', 'wprne'), 390 'settings' => __('Settings', 'wprne'), 391 'deleteConfirm' => __('Are You sure to delete this template?', 'wprne'), 392 'insertTemplate' => __('insert template', 'wprne'), 393 'deleteTemplate' => __('delete template', 'wprne'), 394 'deleteTemplateHeader' => __('Delete Template', 'wprne'), 395 'save' => __('Save', 'wprne'), 396 'pageName' => __('Page Name', 'wprne'), 397 'pageTemplates' => __('Page Templates', 'wprne'), 398 'showHeaderBar' => __('Show Header Bar', 'wprne'), 399 'addBottomTab' => __('Add to Bottom Tab Navigation', 'wprne'), 400 'priority' => __('Priority', 'wprne'), 401 'inactiveColor' => __('Inactive Color', 'wprne'), 402 'addNewPage' => __('add new page', 'wprne'), 403 'addPageDialog' => __('Add New Page', 'wprne'), 404 'deletePageDialog' => __('Delete Page', 'wprne'), 405 'deletePage' => __('delete page', 'wprne'), 406 'duplicatePage' => __('duplicate selected page', 'wprne'), 407 'pageName' => __('Page Name', 'wprne'), 408 'selectedPageSetting' => __('selected page settings', 'wprne'), 409 'toolbarAlert' => __('There is no page. Add a new page from the pages panel on the left.', 'wprne'), 410 'errorSavePages' => __('Something went wrong trying to save pages', 'wprne'), 411 'successSavePages' => __('Pages has been saved', 'wprne'), 412 'previewMode' => __('Preview Mode', 'wprne'), 413 'builderMode' => __('Builder Mode', 'wprne'), 414 'layers' => __('Layers', 'wprne'), 415 'pages' => __('Pages', 'wprne'), 416 'templates' => __('Templates', 'wprne'), 417 'layerPanelAlert' => __('Layers panel only available in builder mode', 'wprne'), 418 'templatePanelAlert' => __('Templates panel only available in builder mode', 'wprne'), 419 'savePages' => __('Save Pages', 'wprne'), 420 'saving' => __('Saving...', 'wprne'), 421 'move' => __('move', 'wprne'), 422 'horizontal' => __('Horizontal', 'wprne'), 423 'vertical' => __('Vertical', 'wprne'), 424 'solid' => __('Solid', 'wprne'), 425 'clear' => __('Clear', 'wprne'), 426 'outline' => __('Outline', 'wprne'), 427 'navigate' => __('navigate', 'wprne'), 428 'goBack' => __('go back', 'wprne'), 429 'atcAction' => __('add to cart', 'wprne'), 430 'toCheckout' => __('to checkout', 'wprne'), 431 'addQty' => __('add cart item quantity', 'wprne'), 432 'reduceQty' => __('reduce cart item quantity', 'wprne'), 433 'yes' => __('Yes', 'wprne'), 434 'no' => __('No', 'wprne'), 435 'wooProducts' => __('Woocommerce Products', 'wprne'), 436 'wooOrders' => __('Woocommerce Orders', 'wprne'), 437 'descending' => __('Descending', 'wprne'), 438 'ascending' => __('Ascending', 'wprne'), 439 'date' => __('Date', 'wprne'), 440 'postId' => __('Post Id', 'wprne'), 441 'modified' => __('Modified', 'wprne'), 442 'all' => __('All', 'wprne'), 443 'selectImage' => __('Select image', 'wprne'), 444 'changeImage' => __('Change image', 'wprne'), 445 'postImage' => __('Post featured image', 'wprne'), 446 'static' => __('static', 'wprne'), 447 'orderId' => __('order number', 'wprne'), 448 'orderStatus' => __('order status', 'wprne'), 449 'orderItem' => __('order item', 'wprne'), 450 'orderTotal' => __('order total', 'wprne'), 451 'shippingTotal' => __('shipping total', 'wprne'), 452 'paymentMethod' => __('payment method', 'wprne'), 453 'totalTax' => __('total tax', 'wprne'), 454 'currencySymbol' => __('currency symbol', 'wprne'), 455 'excerpt' => __('Excerpt', 'wprne'), 456 'content' => __('Content', 'wprne'), 457 'singlePost' => __('Single Post', 'wprne'), 458 'searchPost' => __('Search Post', 'wprne'), 459 'wooSingleProduct' => __('Woocommerce Single Product', 'wprne'), 460 'wooImageCarousel' => __('Product Image Carousel', 'wprne'), 461 'wooCart' => __('Woocommerce Cart', 'wprne'), 462 'cartItem' => __('Cart Item', 'wprne'), 463 'checkoutNative' => __('Woocommerce Checkout', 'wprne'), 464 'checkoutWebView' => __('Checkout Web View', 'wprne'), 465 'youtubePlayer' => __('Youtube Player', 'wprne'), 466 'selectComponent' => __('Select Component', 'wprne'), 467 'relative' => __('Relative', 'wprne'), 468 'absolute' => __('Absolute', 'wprne'), 469 'blank' => __('Blank', 'wprne'), 470 'wooShop' => __('Woocommerce Shop', 'wprne'), 471 'singleProduct' => __('Single Product', 'wprne'), 472 'myOrder' => __('My Order', 'wprne'), 473 'searchProduct' => __('Search Product', 'wprne'), 474 'addTemplateError' => __('Something went wrong trying to save template', 'wprne'), 475 'addTemplateSuccess' => __('Template has been saved', 'wprne'), 476 'saveSettingsError' => __('Something went wrong trying to save settings', 'wprne'), 477 'saveSettingsSuccess' => __('Settings has been saved', 'wprne'), 478 'tutorials' => __('Tutorials', 'wprne'), 479 ); 480 } 475 481 } -
mobile-app-editor/trunk/freemius/includes/class-freemius.php
r2567848 r2695668 3551 3551 */ 3552 3552 static function _toggle_debug_mode() { 3553 check_admin_referer( 'fs_toggle_debug_mode' ); 3554 3553 3555 if ( ! is_super_admin() ) { 3554 3556 return; … … 3572 3574 */ 3573 3575 static function _get_debug_log() { 3576 check_admin_referer( 'fs_get_debug_log' ); 3577 3578 if ( ! is_super_admin() ) { 3579 return; 3580 } 3581 3582 $limit = min( ! empty( $_POST['limit'] ) ? absint( $_POST['limit'] ) : 200, 200 ); 3583 $offset = min( ! empty( $_POST['offset'] ) ? absint( $_POST['offset'] ) : 200, 200 ); 3584 3574 3585 $logs = FS_Logger::load_db_logs( 3575 3586 fs_request_get( 'filters', false, 'post' ), 3576 ! empty( $_POST['limit'] ) && is_numeric( $_POST['limit'] ) ? $_POST['limit'] : 200,3577 ! empty( $_POST['offset'] ) && is_numeric( $_POST['offset'] ) ? $_POST['offset'] : 03587 $limit, 3588 $offset 3578 3589 ); 3579 3590 … … 4448 4459 */ 4449 4460 function _email_about_firewall_issue() { 4461 check_admin_referer( 'fs_resolve_firewall_issues' ); 4462 4463 if ( ! current_user_can( is_multisite() ? 'manage_options' : 'activate_plugins' ) ) { 4464 return; 4465 } 4466 4450 4467 $this->_admin_notices->remove_sticky( 'failed_connect_api' ); 4451 4468 … … 4522 4539 */ 4523 4540 function _retry_connectivity_test() { 4541 check_admin_referer( 'fs_retry_connectivity_test' ); 4542 4543 if ( ! current_user_can( is_multisite() ? 'manage_options' : 'activate_plugins' ) ) { 4544 return; 4545 } 4546 4524 4547 $this->_admin_notices->remove_sticky( 'failed_connect_api_first' ); 4525 4548 -
mobile-app-editor/trunk/freemius/includes/managers/class-fs-admin-notice-manager.php
r2567848 r2695668 176 176 */ 177 177 function dismiss_notice_ajax_callback() { 178 $this->_sticky_storage->remove( $_POST['message_id'] ); 178 check_admin_referer( 'fs_dismiss_notice_action' ); 179 180 if ( ! is_numeric( $_POST['message_id'] ) ) { 181 $this->_sticky_storage->remove( $_POST['message_id'] ); 182 } 183 179 184 wp_die(); 180 185 } -
mobile-app-editor/trunk/freemius/includes/sdk/Exceptions/ArgumentNotExistException.php
r2567848 r2695668 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 2 6 if ( ! class_exists( 'Freemius_InvalidArgumentException' ) ) { 3 7 exit; -
mobile-app-editor/trunk/freemius/includes/sdk/Exceptions/EmptyArgumentException.php
r2567848 r2695668 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 2 6 if ( ! class_exists( 'Freemius_InvalidArgumentException' ) ) { 3 7 exit; -
mobile-app-editor/trunk/freemius/includes/sdk/Exceptions/Exception.php
r2567848 r2695668 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 2 6 if ( ! class_exists( 'Freemius_Exception' ) ) { 3 7 /** -
mobile-app-editor/trunk/freemius/includes/sdk/Exceptions/InvalidArgumentException.php
r2567848 r2695668 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 2 6 if ( ! class_exists( 'Freemius_Exception' ) ) { 3 7 exit; -
mobile-app-editor/trunk/freemius/includes/sdk/Exceptions/OAuthException.php
r2567848 r2695668 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 2 6 if ( ! class_exists( 'Freemius_Exception' ) ) { 3 7 exit; -
mobile-app-editor/trunk/freemius/includes/sdk/FreemiusBase.php
r2567848 r2695668 16 16 */ 17 17 18 if ( ! defined( 'ABSPATH' ) ) { 19 exit; 20 } 21 18 22 if ( ! defined( 'FS_API__VERSION' ) ) { 19 23 define( 'FS_API__VERSION', '1' ); -
mobile-app-editor/trunk/freemius/includes/sdk/FreemiusWordPress.php
r2567848 r2695668 15 15 * under the License. 16 16 */ 17 if ( ! defined( 'ABSPATH' ) ) { 18 exit; 19 } 17 20 18 21 require_once dirname( __FILE__ ) . '/FreemiusBase.php'; -
mobile-app-editor/trunk/freemius/require.php
r2567848 r2695668 6 6 * @since 1.1.9 7 7 */ 8 9 if ( ! defined( 'ABSPATH' ) ) { 10 exit; 11 } 8 12 9 13 // Configuration should be loaded first. -
mobile-app-editor/trunk/freemius/start.php
r2567848 r2695668 16 16 * @var string 17 17 */ 18 $this_sdk_version = '2.4. 2';18 $this_sdk_version = '2.4.3'; 19 19 20 20 #region SDK Selection Logic -------------------------------------------------------------------- -
mobile-app-editor/trunk/freemius/templates/account/partials/addon.php
r2567848 r2695668 1 1 <?php 2 3 if ( ! defined( 'ABSPATH' ) ) { 4 exit; 5 } 6 2 7 /** 3 8 * @var array $VARS -
mobile-app-editor/trunk/freemius/templates/ajax-loader.php
r2567848 r2695668 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) { 3 exit; 4 } 5 ?> 1 6 <div class="fs-ajax-loader" style="display: none"><?php for ( $i = 1; $i <= 8; $i ++ ) : ?><div class="fs-ajax-loader-bar fs-ajax-loader-bar-<?php echo $i ?>"></div><?php endfor ?></div> -
mobile-app-editor/trunk/freemius/templates/debug.php
r2567848 r2695668 38 38 $.post( ajaxurl, { 39 39 action: 'fs_toggle_debug_mode', 40 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 41 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_toggle_debug_mode' ) ); ?>, 40 42 is_on : ($(this).hasClass( 'fs-on' ) ? 1 : 0) 41 43 }, function ( response ) { … … 112 114 $.post(ajaxurl, { 113 115 action : 'fs_get_db_option', 114 _wpnonce : '<?php echo wp_create_nonce( 'fs_get_db_option' ) ?>', 116 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 117 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_get_db_option' ) ); ?>, 115 118 option_name: optionName 116 119 }, function (response) { … … 132 135 $.post(ajaxurl, { 133 136 action : 'fs_set_db_option', 134 _wpnonce : '<?php echo wp_create_nonce( 'fs_set_db_option' ) ?>', 137 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 138 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_set_db_option' ) ); ?>, 135 139 option_name : optionName, 136 140 option_value: optionValue … … 725 729 $.post(ajaxurl, { 726 730 action : 'fs_get_debug_log', 731 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 732 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_get_debug_log' ) ); ?>, 727 733 filters: filters, 728 734 offset : offset, -
mobile-app-editor/trunk/freemius/templates/firewall-issues-js.php
r2567848 r2695668 23 23 ajaxActionSuffix = notice.attr( 'data-manager-id' ).replace( ':', '-' ); 24 24 25 var data = { 26 action : 'fs_resolve_firewall_issues_' + ajaxActionSuffix, 27 error_type: error_type 28 }; 25 var data = { 26 action : 'fs_resolve_firewall_issues_' + ajaxActionSuffix, 27 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 28 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_resolve_firewall_issues' ) ); ?>, 29 error_type: error_type 30 }; 29 31 30 32 if ( 'squid' === error_type ) { … … 40 42 41 43 if ( 'retry_ping' === error_type ) { 42 data.action = 'fs_retry_connectivity_test_' + ajaxActionSuffix; 44 data.action = 'fs_retry_connectivity_test_' + ajaxActionSuffix; 45 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 46 data._wpnonce = <?php echo wp_json_encode( wp_create_nonce( 'fs_retry_connectivity_test' ) ); ?>; 43 47 } 44 48 -
mobile-app-editor/trunk/freemius/templates/partials/network-activation.php
r2567848 r2695668 1 1 <?php 2 3 if ( ! defined( 'ABSPATH' ) ) { 4 exit; 5 } 6 2 7 /** 3 8 * @var array $VARS -
mobile-app-editor/trunk/freemius/templates/sticky-admin-notice-js.php
r2567848 r2695668 24 24 notice.fadeOut( 'fast', function() { 25 25 var data = { 26 action : 'fs_dismiss_notice_action_' + ajaxActionSuffix, 26 action : 'fs_dismiss_notice_action_' + ajaxActionSuffix, 27 // As such we don't need to use `wp_json_encode` method but using it to follow wp.org guideline. 28 _wpnonce : <?php echo wp_json_encode( wp_create_nonce( 'fs_dismiss_notice_action' ) ); ?>, 27 29 message_id: id 28 30 }; -
mobile-app-editor/trunk/includes/class-wprne-rest-api.php
r2695308 r2695668 31 31 public function rest_api_init() 32 32 { 33 33 34 //init data api 34 35 register_rest_route('wprne/v1', '/init/get_init_data', array( -
mobile-app-editor/trunk/mobile-app-editor.php
r2695308 r2695668 9 9 * Plugin URI: https://wprne.xyz/ 10 10 * Description: Drag and drop editor to build mobile app using wordpress. 11 * Version: 1.1. 111 * Version: 1.1.2 12 12 * Author: Mobile App Editor 13 13 * License: GPL-2.0+ … … 20 20 exit; 21 21 } 22 define( "WPRNE_VERSION", "1.1. 1" );22 define( "WPRNE_VERSION", "1.1.2" ); 23 23 define( "WPRNE_PLUGIN_URL", plugins_url( '', __FILE__ ) ); 24 24 -
mobile-app-editor/trunk/readme.txt
r2695308 r2695668 5 5 Tested up to: 5.8.1 6 6 Requires PHP: 5.6 7 Stable tag: 1.1. 17 Stable tag: 1.1.2 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html
Note: See TracChangeset
for help on using the changeset viewer.