| 1 |
<?php |
| 2 |
/** |
| 3 |
* LoginPress Import Export Page Content. |
| 4 |
* |
| 5 |
* This file contains the import/export page content for LoginPress. |
| 6 |
* Purpose of this file is to provide import/export functionality for LoginPress settings. |
| 7 |
* |
| 8 |
* @package LoginPress |
| 9 |
* @since 1.0.19 |
| 10 |
* @version 6.2.0 |
| 11 |
*/ |
| 12 |
|
| 13 |
if ( ! defined( 'ABSPATH' ) ) { |
| 14 |
exit; |
| 15 |
} |
| 16 |
|
| 17 |
$loginpress_import_nonce = wp_create_nonce( 'loginpress-import-nonce' ); |
| 18 |
$loginpress_export_nonce = wp_create_nonce( 'loginpress-export-nonce' ); |
| 19 |
?> |
| 20 |
<div class="loginpress-import-export-page"> |
| 21 |
<h2><?php esc_html_e( 'Import/Export LoginPress Settings', 'loginpress' ); ?></h2> |
| 22 |
<div class=""> |
| 23 |
<?php esc_html_e( 'Import/Export your LoginPress Settings for/from other sites. This will export/import all the settings including Customizer settings as well.', 'loginpress' ); ?> |
| 24 |
</div> |
| 25 |
<table class="form-table"> |
| 26 |
<tbody> |
| 27 |
<tr class="import_setting"> |
| 28 |
<th scope="row"> |
| 29 |
<label |
| 30 |
for="loginpress_configure[import_setting]"><?php esc_html_e( 'Import Settings:', 'loginpress' ); ?></label> |
| 31 |
</th> |
| 32 |
<td> |
| 33 |
<div class="upload-file"><span>Upload File</span><input type="file" name="loginPressImport" |
| 34 |
id="loginPressImport" accept=".json"></div> |
| 35 |
<input type="button" class="button loginpress-import" |
| 36 |
value="<?php esc_html_e( 'Import', 'loginpress' ); ?>" multiple="multiple" disabled="disabled"> |
| 37 |
<input type="hidden" class="loginpress_import_nonce" name="loginpress_import_nonce" |
| 38 |
value="<?php echo esc_attr( $loginpress_import_nonce ); ?>"> |
| 39 |
<span class="import-sniper"> |
| 40 |
<img src="<?php echo esc_url( admin_url( 'images/wpspin_light.gif' ) ); ?>"> |
| 41 |
</span> |
| 42 |
<span |
| 43 |
class="import-text"><?php esc_html_e( 'LoginPress Settings Imported Successfully.', 'loginpress' ); ?></span> |
| 44 |
<span class="wrong-import"></span> |
| 45 |
<p class="description"> |
| 46 |
<?php esc_html_e( 'Select a file and click on Import to start processing.', 'loginpress' ); ?> |
| 47 |
</p> |
| 48 |
</td> |
| 49 |
</tr> |
| 50 |
<tr class="export_setting"> |
| 51 |
<th scope="row"> |
| 52 |
<label |
| 53 |
for="loginpress_configure[export_setting]"><?php esc_html_e( 'Export Settings:', 'loginpress' ); ?></label> |
| 54 |
</th> |
| 55 |
<td> |
| 56 |
<input type="button" class="button loginpress-export" |
| 57 |
value="<?php esc_html_e( 'Export', 'loginpress' ); ?>"> |
| 58 |
<input type="hidden" class="loginpress_export_nonce" name="loginpress_export_nonce" |
| 59 |
value="<?php echo esc_attr( $loginpress_export_nonce ); ?>"> |
| 60 |
<span class="export-sniper"> |
| 61 |
<img src="<?php echo esc_url( admin_url( 'images/wpspin_light.gif' ) ); ?>"> |
| 62 |
</span> |
| 63 |
<span |
| 64 |
class="export-text"><?php esc_html_e( 'LoginPress Settings Exported Successfully!', 'loginpress' ); ?></span> |
| 65 |
<p class="description"><?php esc_html_e( 'Export LoginPress Settings.', 'loginpress' ); ?></p> |
| 66 |
</td> |
| 67 |
</tr> |
| 68 |
</tbody> |
| 69 |
</table> |
| 70 |
</div> |
| 71 |
|