PluginProbe
Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant / 1.7
Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant v1.7
2.3.1 2.3.0 2.2.8 2.2.7 trunk 1.10.0 1.10.1 1.10.2 1.10.3 1.10.4 1.10.5 1.11.0 1.11.1 1.11.2 1.6 1.7 1.8 1.8.1 1.8.2 1.8.3 1.9.0 1.9.1 1.9.10 1.9.11 1.9.12 All 59 releases
merchant / admin / pages / page-settings.php

page-settings.php in Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant 1.7, at admin/pages/page-settings.php

147 lines 4.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if ( ! defined( 'ABSPATH' ) ) {
4 exit; // Exit if accessed directly
5 }
6
7 ?>
8
9 <div class="merchant-module-page">
10
11 <div class="merchant-module-page-content mrc-w-100">
12
13 <form method="post" action="" class="merchant-module-page-ajax-form">
14
15 <input type="hidden" name="merchant_nonce" value="<?php echo esc_attr( wp_create_nonce( 'merchant_nonce' ) ); ?>" />
16
17 <div class="merchant-module-page-ajax-header">
18 <div class="merchant-module-page-ajax-notice"><?php esc_html_e( 'Your settings have been modified. Save?', 'merchant' ); ?></div>
19 <div class="merchant-module-page-ajax-buttons">
20 <a href="<?php echo esc_url( add_query_arg( array( 'page' => 'merchant' ) ) ); ?>" class="merchant-module-discard-button"><?php esc_html_e( 'Discard', 'merchant' ); ?></a>
21 <button type="submit" name="merchant_save" value="save" class="merchant-module-save-button"><span class="merchant-module-save-button-label"><?php esc_html_e( 'Save', 'merchant' ); ?></span><i class="dashicons dashicons-update-alt"></i></button>
22 </div>
23 </div>
24
25 <div class="merchant-module-page-header">
26
27 <div class="merchant-module-page-header-content">
28
29 <div class="merchant-module-page-back">
30 <a href="<?php echo esc_url( add_query_arg( array( 'page' => 'merchant' ), 'admin.php' ) ); ?>">
31 <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
32 <path d="M13.3329 7.20013H4.46628L7.19961 4.20013L6.46628 3.4668L2.59961 7.6668L6.46628 11.5335L7.19961 10.8001L4.53294 8.20013H13.3329V7.20013Z" fill="#1D2327"/>
33 </svg>
34 <span><?php esc_html_e( 'Go Back', 'merchant' ); ?></span>
35 </a>
36 </div>
37
38 <div class="merchant-module-page-heading">
39 <div class="merchant-module-page-info">
40 <div class="merchant-module-page-title">
41 <?php esc_html_e( 'Global Settings', 'merchant' ); ?>
42 </div>
43 <div class="merchant-module-page-desc"><?php esc_html_e( 'License activation, operating mode selection and custom code.', 'merchant' ); ?></div>
44 </div>
45 </div>
46
47 </div>
48
49 </div>
50
51 <div class="merchant-module-page-content mrc-w-100">
52
53 <?php
54
55 /**
56 * Hook: 'merchant_admin_settings_before_options'
57 *
58 * @since 1.0
59 */
60 do_action( 'merchant_admin_settings_before_options' );
61
62 Merchant_Admin_Options::create( array(
63 'module' => 'global-settings',
64 'title' => esc_html__( 'Merchant Operating Mode', 'merchant' ),
65 'fields' => array(
66
67 array(
68 'id' => 'operating_mode',
69 'type' => 'radio_alt',
70 'options' => array(
71 'active' => array(
72 'title' => esc_html__( 'Active', 'merchant' ),
73 'desc' => esc_html__( 'Merchant is active and visible for all customers. This is the standard operating mode.', 'merchant' ),
74 ),
75 'preview' => array(
76 'title' => esc_html__( 'Preview', 'merchant' ),
77 'desc' => esc_html__( 'All Merchant modules are active and visible only to admins. Use this mode to test Merchant modules before going live.', 'merchant' ),
78 ),
79 'inactive' => array(
80 'title' => esc_html__( 'Inactive', 'merchant' ),
81 'desc' => esc_html__( 'Merchant is inactive for everyone, including you. While in this mode, your store operates like Merchant is not installed.', 'merchant' ),
82 ),
83 ),
84 'default' => 'active',
85 ),
86
87 ),
88 ) );
89
90 Merchant_Admin_Options::create( array(
91 'module' => 'global-settings',
92 'title' => esc_html__( 'Global Customizations', 'merchant' ),
93 'fields' => array(
94
95 array(
96 'type' => 'warning',
97 'content' => esc_html__( 'Do not modify these settings unless you\'re an experienced developer', 'merchant' ),
98 ),
99
100 array(
101 'type' => 'divider',
102 ),
103
104 array(
105 'id' => 'custom_css',
106 'type' => 'textarea',
107 'title' => esc_html__( 'Custom CSS', 'merchant' ),
108 ),
109
110 array(
111 'id' => 'custom_js_first',
112 'type' => 'textarea',
113 'title' => esc_html__( 'Custom JS First - runs at the beginning of Merchant', 'merchant' ),
114 ),
115
116 array(
117 'id' => 'custom_js_last',
118 'type' => 'textarea',
119 'title' => esc_html__( 'Custom JS Last - runs at the end of Merchant', 'merchant' ),
120 ),
121
122 array(
123 'id' => 'custom_js',
124 'type' => 'textarea',
125 'title' => esc_html__( 'Custom JS', 'merchant' ),
126 ),
127
128 ),
129 ) );
130
131 /**
132 * Hook: 'merchant_admin_settings_after_options'
133 *
134 * @since 1.0
135 */
136 do_action( 'merchant_admin_settings_after_options' );
137
138 ?>
139
140 </div>
141
142 </form>
143
144 </div>
145
146 </div>
147