index.php
241 lines
| 1 | <style type="text/css"> |
| 2 | .wpae-shake { |
| 3 | -webkit-animation: wpae_shake 0.4s 1 linear; |
| 4 | -moz-animation: wpae_shake 0.4s 1 linear; |
| 5 | -o-animation: wpae_shake 0.4s 1 linear; |
| 6 | } |
| 7 | @-webkit-keyframes wpae_shake { |
| 8 | 0% { -webkit-transform: translate(30px); } |
| 9 | 20% { -webkit-transform: translate(-30px); } |
| 10 | 40% { -webkit-transform: translate(15px); } |
| 11 | 60% { -webkit-transform: translate(-15px); } |
| 12 | 80% { -webkit-transform: translate(8px); } |
| 13 | 100% { -webkit-transform: translate(0px); } |
| 14 | } |
| 15 | @-moz-keyframes wpae_shake { |
| 16 | 0% { -moz-transform: translate(30px); } |
| 17 | 20% { -moz-transform: translate(-30px); } |
| 18 | 40% { -moz-transform: translate(15px); } |
| 19 | 60% { -moz-transform: translate(-15px); } |
| 20 | 80% { -moz-transform: translate(8px); } |
| 21 | 100% { -moz-transform: translate(0px); } |
| 22 | } |
| 23 | @-o-keyframes wpae_shake { |
| 24 | 0% { -o-transform: translate(30px); } |
| 25 | 20% { -o-transform: translate(-30px); } |
| 26 | 40% { -o-transform: translate(15px); } |
| 27 | 60% { -o-transform: translate(-15px); } |
| 28 | 80% { -o-transform: translate(8px); } |
| 29 | 100% { -o-origin-transform: translate(0px); } |
| 30 | } |
| 31 | </style> |
| 32 | |
| 33 | <form class="settings" method="post" action="<?php echo $this->baseUrl ?>" enctype="multipart/form-data"> |
| 34 | |
| 35 | <div class="wpallexport-header"> |
| 36 | <div class="wpallexport-logo"></div> |
| 37 | <div class="wpallexport-title"> |
| 38 | <h3><?php _e('Settings', 'wp_all_export_plugin'); ?></h3> |
| 39 | </div> |
| 40 | </div> |
| 41 | <h2 style="padding:0px;"></h2> |
| 42 | |
| 43 | <div class="wpallexport-setting-wrapper"> |
| 44 | <?php if ($this->errors->get_error_codes()): ?> |
| 45 | <?php $this->error() ?> |
| 46 | <?php endif ?> |
| 47 | |
| 48 | <h3><?php _e('Import/Export Templates', 'wp_all_export_plugin') ?></h3> |
| 49 | <?php $templates = new PMXE_Template_List(); $templates->getBy()->convertRecords() ?> |
| 50 | <?php wp_nonce_field('delete-templates', '_wpnonce_delete-templates') ?> |
| 51 | <?php if ($templates->total()): ?> |
| 52 | <table> |
| 53 | <?php foreach ($templates as $t): ?> |
| 54 | <tr> |
| 55 | <td> |
| 56 | <label class="selectit" for="template-<?php echo $t->id ?>"><input id="template-<?php echo $t->id ?>" type="checkbox" name="templates[]" value="<?php echo $t->id ?>" /> <?php echo $t->name ?></label> |
| 57 | </td> |
| 58 | </tr> |
| 59 | <?php endforeach ?> |
| 60 | </table> |
| 61 | <p class="submit-buttons"> |
| 62 | <input type="submit" class="button-primary" name="delete_templates" value="<?php _e('Delete Selected', 'wp_all_export_plugin') ?>" /> |
| 63 | <input type="submit" class="button-primary" name="export_templates" value="<?php _e('Export Selected', 'wp_all_export_plugin') ?>" /> |
| 64 | </p> |
| 65 | <?php else: ?> |
| 66 | <em><?php _e('There are no templates saved', 'wp_all_export_plugin') ?></em> |
| 67 | <?php endif ?> |
| 68 | <p> |
| 69 | <input type="hidden" name="is_templates_submitted" value="1" /> |
| 70 | <input type="file" name="template_file"/> |
| 71 | <input type="submit" class="button-primary" name="import_templates" value="<?php _e('Import Templates', 'wp_all_export_plugin') ?>" /> |
| 72 | </p> |
| 73 | </div> |
| 74 | |
| 75 | </form> |
| 76 | <br /> |
| 77 | |
| 78 | <form name="settings" class="settings" method="post" action="<?php echo $this->baseUrl ?>"> |
| 79 | |
| 80 | <h3><?php _e('Files', 'wp_all_export_plugin') ?></h3> |
| 81 | |
| 82 | <table class="form-table"> |
| 83 | <tbody> |
| 84 | <tr> |
| 85 | <th scope="row"><label><?php _e('Secure Mode', 'wp_all_export_plugin'); ?></label></th> |
| 86 | <td> |
| 87 | <fieldset style="padding:0;"> |
| 88 | <legend class="screen-reader-text"><span><?php _e('Secure Mode', 'wp_all_export_plugin'); ?></span></legend> |
| 89 | <input type="hidden" name="secure" value="0"/> |
| 90 | <label for="secure"><input type="checkbox" value="1" id="secure" name="secure" <?php echo (($post['secure']) ? 'checked="checked"' : ''); ?>><?php _e('Randomize folder names', 'wp_all_export_plugin'); ?></label> |
| 91 | </fieldset> |
| 92 | <p class="description"> |
| 93 | <?php |
| 94 | $wp_uploads = wp_upload_dir(); |
| 95 | ?> |
| 96 | <?php printf(__('If enabled, exported files and temporary files will be saved in a folder with a randomized name in %s.<br/><br/>If disabled, exported files will be saved in the Media Library.', 'wp_all_export_plugin'), $wp_uploads['basedir'] . DIRECTORY_SEPARATOR . WP_ALL_EXPORT_UPLOADS_BASE_DIRECTORY ); ?> |
| 97 | </p> |
| 98 | <p class="submit-buttons"> |
| 99 | <?php wp_nonce_field('edit-settings', '_wpnonce_edit-settings') ?> |
| 100 | <input type="hidden" name="is_settings_submitted" value="1" /> |
| 101 | <input type="submit" class="button-primary" value="Save Settings" /> |
| 102 | </p> |
| 103 | </td> |
| 104 | </tr> |
| 105 | </tbody> |
| 106 | </table> |
| 107 | |
| 108 | <h3><?php _e('Zapier Integration', 'wp_all_export_plugin') ?></h3> |
| 109 | |
| 110 | <table class="form-table"> |
| 111 | <tbody> |
| 112 | <tr> |
| 113 | <th scope="row"><label><?php _e('Getting Started', 'wp_all_export_plugin'); ?></label></th> |
| 114 | <td> |
| 115 | <p class="description"><?php printf(__('Zapier acts as a middle man between WP All Export and hundreds of other popular apps. To get started go to Zapier.com, create an account, and make a new Zap. Read more: <a target="_blank" href="https://zapier.com/zapbook/wp-all-export-pro/">https://zapier.com/zapbook/wp-all-export-pro/</a>', 'wp_all_export_plugin'), "https://zapier.com/zapbook/wp-all-export-pro/"); ?></p> |
| 116 | </td> |
| 117 | </tr> |
| 118 | <tr> |
| 119 | <th scope="row"><label><?php _e('API Key', 'wp_all_export_plugin'); ?></label></th> |
| 120 | <td> |
| 121 | <input type="text" class="regular-text" name="zapier_api_key" readOnly="readOnly" value=""/> |
| 122 | <input type="submit" class="button-secondary generate-zapier-api-key" name="pmxe_generate_zapier_api_key" value="<?php _e('Generate API Key', 'wp_all_export_plugin'); ?>"/> |
| 123 | <p class="description"><?php _e('Changing the key will require you to update your existing Zaps on Zapier.', 'wp_all_export_plugin'); ?></p> |
| 124 | </td> |
| 125 | </tr> |
| 126 | </tbody> |
| 127 | </table> |
| 128 | |
| 129 | <div class="wpallexport-free-edition-notice zapier-upgrade" style="margin: 15px 0; padding: 20px; display: none;"> |
| 130 | <a class="upgrade_link" target="_blank" href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=2707173&edd_options%5Bprice_id%5D=1&utm_source=export-plugin-free&utm_medium=upgrade-notice&utm_campaign=zapier"><?php _e('Upgrade to the Pro edition of WP All Export for Zapier Integration','wp_all_export_plugin');?></a> |
| 131 | <p><?php _e('If you already own it, remove the free edition and install the Pro edition.', 'wp_all_export_plugin'); ?></p> |
| 132 | </div> |
| 133 | |
| 134 | <div class="clear"></div> |
| 135 | </form> |
| 136 | |
| 137 | <form name="settings" method="post" action="" class="settings"> |
| 138 | |
| 139 | <table class="form-table"> |
| 140 | <tbody> |
| 141 | |
| 142 | <tr> |
| 143 | <th scope="row"><label><?php _e('Automatic Scheduling License Key', 'wp_all_export_plugin'); ?></label></th> |
| 144 | <td> |
| 145 | <input type="password" class="regular-text" name="scheduling_license" |
| 146 | value="<?php if (!empty($post['scheduling_license'])) esc_attr_e(PMXE_Plugin::decode($post['scheduling_license'])); ?>"/> |
| 147 | <?php if (!empty($post['scheduling_license'])) { ?> |
| 148 | |
| 149 | <?php if (!empty($post['scheduling_license_status']) && $post['scheduling_license_status'] == 'valid') { ?> |
| 150 | <div class="license-status inline updated"><?php _e('Active', 'wp_all_export_plugin'); ?></div> |
| 151 | <?php } else { ?> |
| 152 | <input type="submit" class="button-secondary" name="pmxe_scheduling_license_activate" |
| 153 | value="<?php _e('Activate License', 'wp_all_export_plugin'); ?>"/> |
| 154 | <div class="license-status inline error"><?php echo $post['scheduling_license_status']; ?></div> |
| 155 | <?php } ?> |
| 156 | |
| 157 | <?php } ?> |
| 158 | <?php |
| 159 | $scheduling = \Wpae\Scheduling\Scheduling::create(); |
| 160 | if(!($scheduling->checkLicense())){ |
| 161 | ?> |
| 162 | <p class="description"><?php _e('A license key is required to use Automatic Scheduling. If you have already subscribed, <a href="https://www.wpallimport.com/portal/automatic-scheduling/" target="_blank">click here to access your license key</a>.<br>If you don\'t have a license, <a href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=515704&utm_source=export-plugin-free&utm_medium=upgrade-notice&utm_campaign=automatic-scheduling" target="_blank">click here to subscribe</a>.', 'wp_all_export_plugin'); ?></p> |
| 163 | <?php |
| 164 | } |
| 165 | ?> |
| 166 | |
| 167 | <p class="submit-buttons"> |
| 168 | <?php wp_nonce_field('edit-license', '_wpnonce_edit-scheduling-license') ?> |
| 169 | <input type="hidden" name="is_scheduling_license_submitted" value="1"/> |
| 170 | <input type="submit" class="button-primary" value="Save License"/> |
| 171 | </p> |
| 172 | </td> |
| 173 | </tr> |
| 174 | </tbody> |
| 175 | </table> |
| 176 | </form> |
| 177 | <form name="client-mode-settings" method="post" action="" class="client-mode-settings"> |
| 178 | |
| 179 | <div> |
| 180 | <h3>Client Mode</h3> |
| 181 | <div style="float: left; width: 20%;"> |
| 182 | Roles With Access |
| 183 | </div> |
| 184 | <div style="float: left; width: 70%;"> |
| 185 | |
| 186 | <?php foreach ($roles as $key => $role) { |
| 187 | $roleObject = get_role($key); |
| 188 | ?> |
| 189 | <input type="checkbox" id="role-<?php echo $key; ?>" |
| 190 | value="<?php echo $key; ?>" |
| 191 | <?php if(isset($post['client_mode_roles']) && is_array($post['client_mode_roles']) && in_array($key, $post['client_mode_roles'])) {?> checked="checked" <?php } ?> |
| 192 | <?php if($roleObject->has_cap('manage_options')) {?> disabled="disabled" checked="checked" <?php }?> |
| 193 | name="client_mode_roles[]"/> |
| 194 | <label |
| 195 | for="role-<?php echo $key; ?>"><?php echo $role['name']; ?> <br/></label> |
| 196 | <?php } ?> |
| 197 | |
| 198 | <p class="submit-buttons"> |
| 199 | <?php wp_nonce_field('edit-client-mode-settings', '_wpnonce_edit-client_mode_settings') ?> |
| 200 | <div class="input wp_all_export_save_client_mode_container"> |
| 201 | <input type="button" class="button-primary wp_all_export_save_client_mode" value="<?php _e("Save Client Mode Settings", 'wp_all_export_plugin'); ?>"/> |
| 202 | </div> |
| 203 | </p> |
| 204 | </div> |
| 205 | <div class="clear"></div> |
| 206 | <div class="wpallexport-free-edition-notice php-client-mode-upgrade" style="margin: 15px 0; padding: 20px; display: none;"> |
| 207 | <a class="upgrade_link" target="_blank" href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=2707173&edd_options%5Bprice_id%5D=1&utm_source=export-plugin-free&utm_medium=upgrade-notice&utm_campaign=client-mode"><?php _e('Upgrade to the Pro edition of WP All Export to enable Client Mode','wp_all_export_plugin');?></a> |
| 208 | <p><?php _e('If you already own it, remove the free edition and install the Pro edition.', 'wp_all_export_plugin'); ?></p> |
| 209 | </div> |
| 210 | </div> |
| 211 | </form> |
| 212 | |
| 213 | <?php |
| 214 | $uploads = wp_upload_dir(); |
| 215 | $functions = $uploads['basedir'] . DIRECTORY_SEPARATOR . WP_ALL_EXPORT_UPLOADS_BASE_DIRECTORY . DIRECTORY_SEPARATOR . 'functions.php'; |
| 216 | ?> |
| 217 | <hr /> |
| 218 | <div class="function-editor"> |
| 219 | <h3><?php _e('Function Editor', 'pmxe_plugin') ?></h3> |
| 220 | |
| 221 | <textarea id="wp_all_export_code" name="wp_all_export_code"><?php echo "<?php\n\n?>";?></textarea> |
| 222 | <div class="wpallexport-free-edition-notice php-functions-upgrade" style="margin: 15px 0; padding: 20px; display: none;"> |
| 223 | <a class="upgrade_link" target="_blank" href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=2707173&edd_options%5Bprice_id%5D=1&utm_source=export-plugin-free&utm_medium=upgrade-notice&utm_campaign=function-editor"><?php _e('Upgrade to the Pro edition of WP All Export to enable the Function Editor','wp_all_export_plugin');?></a> |
| 224 | <p><?php _e('If you already own it, remove the free edition and install the Pro edition.', 'wp_all_export_plugin'); ?></p> |
| 225 | </div> |
| 226 | |
| 227 | <div class="input" style="margin-top: 10px;"> |
| 228 | |
| 229 | <div class="input wp_all_export_save_functions_container" style="display:inline-block; margin-right: 20px;"> |
| 230 | <input type="button" class="button-primary wp_all_export_save_functions" value="<?php _e("Save Functions", 'wp_all_export_plugin'); ?>"/> |
| 231 | <a href="#help" class="wpallexport-help" title="<?php printf(__("Add functions here for use during your export. You can access this file at %s", "wp_all_export_plugin"), preg_replace("%.*wp-content%", "wp-content", $functions));?>" style="top: 0;">?</a> |
| 232 | <div class="wp_all_export_functions_preloader"></div> |
| 233 | </div> |
| 234 | <div class="input wp_all_export_saving_status"> |
| 235 | |
| 236 | </div> |
| 237 | |
| 238 | </div> |
| 239 | </div> |
| 240 | <a href="http://soflyy.com/" target="_blank" class="wpallexport-created-by"><?php _e('Created by', 'wp_all_export_plugin'); ?> <span></span></a> |
| 241 |