necessary-settings.php
61 lines
| 1 | <?php |
| 2 | // If this file is called directly, abort. |
| 3 | if ( ! defined( 'WPINC' ) ) { |
| 4 | die; |
| 5 | } |
| 6 | ?> |
| 7 | <style> |
| 8 | .vvv_textbox{ |
| 9 | height: 150px; |
| 10 | width:100%; |
| 11 | } |
| 12 | #wpbody-content .notice { |
| 13 | margin: 5px 20px 15px 0; |
| 14 | } |
| 15 | .notice, div.updated, div.error{ |
| 16 | margin: 5px 20px 15px 0; |
| 17 | } |
| 18 | </style> |
| 19 | <script type="text/javascript"> |
| 20 | var cli_success_message='<?php echo esc_html__( 'Settings updated.', 'cookie-law-info' ); ?>'; |
| 21 | var cli_error_message='<?php echo esc_html__( 'Unable to update Settings.', 'cookie-law-info' ); ?>'; |
| 22 | </script> |
| 23 | <div class="wrap"> |
| 24 | <?php include_once CLI_PLUGIN_PATH . 'admin/partials/wt-cli-update-banner.php'; ?> |
| 25 | <div class="cookie-law-info-form-container"> |
| 26 | <div class="cli-plugin-toolbar top"> |
| 27 | <h3><?php echo esc_html__( 'Necessary Cookie Settings', 'cookie-law-info' ); ?></h3> |
| 28 | </div> |
| 29 | <?php $form_action = isset( $_SERVER['REQUEST_URI'] ) ? sanitize_text_field( wp_unslash( $_SERVER['REQUEST_URI'] ) ) : ''; ?> |
| 30 | |
| 31 | <form method="post" action="<?php echo esc_url( $form_action ); ?>" id="cli_ncessary_form" class="cookie-sensitivity-form"> |
| 32 | <?php wp_nonce_field( 'cookielawinfo-update-necessary' ); ?> |
| 33 | <table class="form-table cli_necessary_form cli-admin-table"> |
| 34 | <tr> |
| 35 | <td> |
| 36 | <label for="wt_cli_necessary_title"><?php echo esc_html__( 'Title', 'cookie-law-info' ); ?></label> |
| 37 | <input type="text" id="wt_cli_necessary_title" name="wt_cli_necessary_title" value="<?php echo esc_attr( stripslashes( $settings['title'] ) ); ?>" class="cli-textbox" /> |
| 38 | </td> |
| 39 | </tr> |
| 40 | <tr> |
| 41 | <td> |
| 42 | <label for="necessary_description"><?php echo esc_html__( 'Description', 'cookie-law-info' ); ?></label> |
| 43 | <textarea name="necessary_description" class="vvv_textbox"><?php echo wp_kses_post( apply_filters( 'format_to_edit', stripslashes( $settings['description'] ) ) ); ?> |
| 44 | </textarea> |
| 45 | </td> |
| 46 | </tr> |
| 47 | |
| 48 | </table> |
| 49 | <div class="cli-plugin-toolbar bottom"> |
| 50 | <div class="left"> |
| 51 | </div> |
| 52 | <div class="right"> |
| 53 | <input type="hidden" name="cli_necessary_ajax_update" value="1"> |
| 54 | <input type="submit" name="update_admin_settings_form" value="<?php echo esc_html__( 'Update Settings', 'cookie-law-info' ); ?>" class="button-primary" style="float:right;" onClick="return cli_store_settings_btn_click(this.name)" /> |
| 55 | <span class="spinner" style="margin-top:9px"></span> |
| 56 | </div> |
| 57 | </div> |
| 58 | </form> |
| 59 | </div> |
| 60 | </div> |
| 61 |