PluginProbe
WP Directory Kit / 1.5.9
WP Directory Kit v1.5.9
1.5.9 1.5.7 1.5.6 1.5.5 1.5.4 1.5.3 trunk 1.1.0 1.1.6 1.1.8 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.8 All 37 releases
← All changes | application/views/wdk_fields/field_edit.php +212 -108 1.3.3 → 1.5.9 View file →
@@ -1,5 +1,6 @@
1 1 <?php
2 +
2 3 /**
3 4 * The template for Edit Field.
4 5 *
5 6 * This is the template that form edit
@@ -5,178 +6,228 @@
5 6 * This is the template that form edit
6 7 *
7 8 */
8 9
9 -if ( ! defined( 'ABSPATH' ) ) {
10 - exit; // Exit if accessed directly.
10 +if (! defined('ABSPATH')) {
11 + exit; // Exit if accessed directly.
11 12 }
12 13 ?>
13 14 <!-- This file should primarily consist of HTML with a little bit of PHP. -->
14 15
15 16 <div class="wrap wdk-wrap">
16 - <h1 class="wp-heading-inline"><?php echo __('Fields Management','wpdirectorykit'); ?></h1>
17 - <br /><br />
17 + <h1 class="wp-heading-inline"><?php echo esc_html__('Fields Management', 'wpdirectorykit'); ?></h1>
18 + <br />
18 19 <div class="wdk-body">
19 20 <div class="postbox" style="display: block;">
20 21 <div class="postbox-header">
21 - <h3><?php echo __('Add/Edit Field','wpdirectorykit'); ?></h3>
22 + <h3><?php echo esc_html__('Add/Edit Field', 'wpdirectorykit'); ?></h3>
22 23 </div>
23 24 <div class="inside">
24 25
25 - <form method="post" action="<?php echo esc_url(wmvc_current_edit_url()); ?>" novalidate="novalidate">
26 + <form method="post" class="form_listing_ai" action="<?php echo esc_url(wmvc_current_edit_url()); ?>" novalidate="novalidate">
26 27
27 - <?php wp_nonce_field( 'wdk-fields-edit_'.wmvc_show_data('idfield', $db_data, 0), '_wpnonce'); ?>
28 + <?php wp_nonce_field('wdk-fields-edit_' . wmvc_show_data('idfield', $db_data, 0), '_wpnonce'); ?>
28 29
29 - <?php
30 - $form->messages('class="alert alert-danger"', sprintf(__('Successfully saved, <a href="%1$s">Back to Fields Management </a>','wpdirectorykit'),admin_url('admin.php?page=wdk_fields')));
30 + <?php
31 + $form->messages(
32 + 'class="alert alert-danger"',
33 + wp_kses(
34 + sprintf(
35 + /* translators: 1: URL. */
36 + __('Successfully saved, <a href="%1$s">Back to Fields Management </a>', 'wpdirectorykit'),
37 + esc_url(admin_url('admin.php?page=wdk_fields'))
38 + ),
39 + array(
40 + 'a' => array(
41 + 'href' => true,
42 + ),
43 + )
44 + )
45 + );
31 46 ?>
32 47
33 48 <table class="form-table" role="presentation">
34 49 <tbody>
35 - <?php if(wmvc_show_data('field_type', $db_data) != "SECTION"):?>
50 + <?php if (wmvc_show_data('field_type', $db_data) != "SECTION"): ?>
51 + <tr>
52 + <th scope="row">
53 + <label for="field_type"><?php echo esc_html__('Section', 'wpdirectorykit'); ?></label>
54 + </th>
55 + <td>
56 + <?php
57 + echo wp_kses(
58 + wmvc_select_option('section', $section_list, $selected_section),
59 + array(
60 + 'select' => array(
61 + 'id' => true,
62 + 'name' => true,
63 + 'class' => true,
64 + 'style' => true,
65 + 'multiple' => true,
66 + 'size' => true,
67 + ),
68 + 'option' => array(
69 + 'value' => true,
70 + 'selected' => true,
71 + 'disabled' => true,
72 + ),
73 + )
74 + );
75 +
76 + ?>
77 + </td>
78 + </tr>
79 + <?php endif; ?>
36 80 <tr>
37 81 <th scope="row">
38 - <label for="field_type"><?php echo __('Section','wpdirectorykit'); ?></label>
82 + <label for="field_type"><?php echo esc_html__('Field Type', 'wpdirectorykit'); ?></label>
39 83 </th>
40 84 <td>
41 - <?php
42 - echo wmvc_select_option('section', $section_list, (!empty(wmvc_show_data('idfield', $db_data, '')) && isset($fields_categories[wmvc_show_data('idfield', $db_data, '')])) ? $fields_categories[wmvc_show_data('idfield', $db_data)] : '');
85 + <?php
86 + echo wp_kses(
87 + wmvc_select_option('field_type', $field_types, wmvc_show_data('field_type', $db_data, '')),
88 + array(
89 + 'select' => array(
90 + 'id' => true,
91 + 'name' => true,
92 + 'class' => true,
93 + 'style' => true,
94 + 'multiple' => true,
95 + 'size' => true,
96 + ),
97 + 'option' => array(
98 + 'value' => true,
99 + 'selected' => true,
100 + 'disabled' => true,
101 + ),
102 + )
103 + );
104 +
43 105 ?>
44 106 </td>
45 107 </tr>
46 - <?php endif;?>
47 108 <tr>
48 109 <th scope="row">
49 - <label for="field_type"><?php echo __('Field Type','wpdirectorykit'); ?></label>
110 + <label for="date_format"><?php echo esc_html__('Date format', 'wpdirectorykit'); ?></label>
50 111 </th>
51 112 <td>
52 - <?php
53 - echo wmvc_select_option('field_type', $field_types, wmvc_show_data('field_type', $db_data, ''));
54 - ?>
55 - </td>
56 - </tr>
57 - <tr>
58 - <th scope="row">
59 - <label for="date_format"><?php echo __('Date format','wpdirectorykit'); ?></label>
60 - </th>
61 - <td>
62 113 <input name="date_format" type="text" id="date_format"
63 - value="<?php echo wmvc_show_data('date_format', $db_data, ''); ?>"
114 + value="<?php echo esc_attr(wmvc_show_data('date_format', $db_data, '')); ?>"
64 115 class="regular-text">
65 - <p class="description" id="hint-description">
66 - <?php echo __('Date Format for Front - End View','wpdirectorykit'); ?>
116 + <p class="description" id="hint-description">
117 + <?php echo esc_html__('Date Format for Front - End View', 'wpdirectorykit'); ?>
67 118 </p>
68 119 </td>
69 120 </tr>
70 121 <tr>
71 122 <th scope="row">
72 - <label for="field_label"><?php echo __('Field Label','wpdirectorykit'); ?></label>
123 + <label for="field_label"><?php echo esc_html__('Field Label', 'wpdirectorykit'); ?></label>
73 124 </th>
74 125 <td>
75 126 <input name="field_label" type="text" id="field_label"
76 - value="<?php echo wmvc_show_data('field_label', $db_data, ''); ?>"
127 + value="<?php echo esc_attr(wmvc_show_data('field_label', $db_data, '')); ?>"
77 128 class="regular-text">
78 -
129 +
79 130 </td>
80 131 </tr>
81 132 <tr>
82 - <th scope="row"><label for="hint"><?php echo __('Hint','wpdirectorykit'); ?></label>
133 + <th scope="row"><label for="hint"><?php echo esc_html__('Hint', 'wpdirectorykit'); ?></label>
83 134 </th>
84 135 <td>
85 136 <input name="hint" type="text" id="hint"
86 - value="<?php echo wmvc_show_data('hint', $db_data, ''); ?>"
137 + value="<?php echo esc_attr(wmvc_show_data('hint', $db_data, '')); ?>"
87 138 class="regular-text">
88 139 <p class="description" id="hint-description">
89 - <?php echo __('Hint is showing below fields like this one','wpdirectorykit'); ?>
140 + <?php echo esc_html__('Hint is showing below fields like this one', 'wpdirectorykit'); ?>
90 141 </p>
91 142 </td>
92 143 </tr>
93 144 <tr>
94 - <th scope="row"><label for="placeholder"><?php echo __('Placeholder','wpdirectorykit'); ?></label>
145 + <th scope="row"><label for="placeholder"><?php echo esc_html__('Placeholder', 'wpdirectorykit'); ?></label>
95 146 </th>
96 147 <td>
97 148 <input name="placeholder" type="text" id="placeholder"
98 - value="<?php echo wmvc_show_data('placeholder', $db_data, ''); ?>"
149 + value="<?php echo esc_attr(wmvc_show_data('placeholder', $db_data, '')); ?>"
99 150 class="regular-text">
100 151 <p class="description" id="placeholder-description">
101 - <?php echo __('Placeholder is showing on placeholder of fields or first value on dropdown','wpdirectorykit'); ?>
152 + <?php echo esc_html__('Placeholder is showing on placeholder of fields or first value on dropdown', 'wpdirectorykit'); ?>
102 153 </p>
103 154 </td>
104 155 </tr>
105 156 <tr>
106 157 <th scope="row"><label
107 - for="columns_number"><?php echo __('Columns number/Width','wpdirectorykit'); ?></label>
158 + for="columns_number"><?php echo esc_html__('Columns number/Width', 'wpdirectorykit'); ?></label>
108 159 </th>
109 160 <td>
110 161 <input name="columns_number" type="number" id="columns_number"
111 - value="<?php echo wmvc_show_data('columns_number', $db_data, ''); ?>"
162 + value="<?php echo esc_attr(wmvc_show_data('columns_number', $db_data, '')); ?>"
112 163 class="regular-text">
113 164 <p class="description" id="columns_number-description">
114 - <?php echo __('Full width is 12 columns, so define wanted columns allocation number for this field','wpdirectorykit'); ?>
165 + <?php echo esc_html__('Full width is 12 columns, so define wanted columns allocation number for this field', 'wpdirectorykit'); ?>
115 166 </p>
116 167 </td>
117 168 </tr>
118 169 <tr>
119 - <th scope="row"><?php echo __('Field is required','wpdirectorykit'); ?></th>
170 + <th scope="row"><?php echo esc_html__('Field is required', 'wpdirectorykit'); ?></th>
120 171 <td>
121 172 <fieldset>
122 173 <legend class="screen-reader-text">
123 - <span><?php echo __('Field is required','wpdirectorykit'); ?></span>
174 + <span><?php echo esc_html__('Field is required', 'wpdirectorykit'); ?></span>
124 175 </legend>
125 176 <label for="is_required">
126 177 <input name="is_required" type="checkbox" id="is_required"
127 178 value="1"
128 - <?php echo !empty(wmvc_show_data('is_required', $db_data, ''))?'checked':''; ?>>
129 - <?php echo __('Required','wpdirectorykit'); ?>
130 - <?php echo __('( Not for section type)','wpdirectorykit'); ?>
179 + <?php echo !empty(wmvc_show_data('is_required', $db_data, '')) ? 'checked' : ''; ?>>
180 + <?php echo esc_html__('Required', 'wpdirectorykit'); ?>
181 + <?php echo esc_html__('( Not for section type)', 'wpdirectorykit'); ?>
131 182 </label>
132 183 </fieldset>
133 184 </td>
134 185 </tr>
135 186 <tr>
136 - <th scope="row"><?php echo __('Field is visible on Listing Preview','wpdirectorykit'); ?></th>
187 + <th scope="row"><?php echo esc_html__('Field is visible on Listing Preview', 'wpdirectorykit'); ?></th>
137 188 <td>
138 189 <fieldset>
139 190 <legend class="screen-reader-text">
140 - <span><?php echo __('Field is visible on Listing Preview','wpdirectorykit'); ?></span>
191 + <span><?php echo esc_html__('Field is visible on Listing Preview', 'wpdirectorykit'); ?></span>
141 192 </legend>
142 193 <label for="is_visible_frontend">
143 194 <input name="is_visible_frontend" type="checkbox" id="is_visible_frontend"
144 195 value="1"
145 - <?php echo !empty(wmvc_show_data('is_visible_frontend', $db_data, ''))?'checked':''; ?>>
146 - <?php echo __('( Not for section type)','wpdirectorykit'); ?>
196 + <?php echo !empty(wmvc_show_data('is_visible_frontend', $db_data, '')) ? 'checked' : ''; ?>>
197 + <?php echo esc_html__('( Not for section type)', 'wpdirectorykit'); ?>
147 198 </label>
148 199 </fieldset>
149 200 </td>
150 201 </tr>
151 202 <tr>
152 - <th scope="row"><?php echo __('Field is visible on frontend submission','wpdirectorykit'); ?></th>
203 + <th scope="row"><?php echo esc_html__('Field is visible on frontend submission', 'wpdirectorykit'); ?></th>
153 204 <td>
154 205 <fieldset>
155 206 <legend class="screen-reader-text">
156 - <span><?php echo __('Field is visible on frontend submission','wpdirectorykit'); ?></span>
207 + <span><?php echo esc_html__('Field is visible on frontend submission', 'wpdirectorykit'); ?></span>
157 208 </legend>
158 209 <label for="is_visible_dashboard">
159 210 <input name="is_visible_dashboard" type="checkbox" id="is_visible_dashboard"
160 211 value="1"
161 - <?php echo !empty(wmvc_show_data('is_visible_dashboard', $db_data, ''))?'checked':''; ?>>
162 - <?php echo __('( Not for section type)','wpdirectorykit'); ?>
212 + <?php echo !empty(wmvc_show_data('is_visible_dashboard', $db_data, '')) ? 'checked' : ''; ?>>
213 + <?php echo esc_html__('( Not for section type)', 'wpdirectorykit'); ?>
163 214 </label>
164 215 </fieldset>
165 216 </td>
166 217 </tr>
167 218 <tr>
168 - <th scope="row"><?php echo __('Price format','wpdirectorykit'); ?></th>
219 + <th scope="row"><?php echo esc_html__('Price format', 'wpdirectorykit'); ?></th>
169 220 <td>
170 221 <fieldset>
171 222 <legend class="screen-reader-text">
172 - <span><?php echo __('Price format','wpdirectorykit'); ?></span>
223 + <span><?php echo esc_html__('Price format', 'wpdirectorykit'); ?></span>
173 224 </legend>
174 225 <label for="is_price_format">
175 226 <input name="is_price_format" type="checkbox" id="is_price_format"
176 227 value="1"
177 - <?php echo !empty(wmvc_show_data('is_price_format', $db_data, ''))?'checked':''; ?>>
178 - <?php echo __('Use wp price format based on language ( Only for number field type)','wpdirectorykit'); ?>
228 + <?php echo !empty(wmvc_show_data('is_price_format', $db_data, '')) ? 'checked' : ''; ?>>
229 + <?php echo esc_html__('Use wp price format based on language ( Only for number field type)', 'wpdirectorykit'); ?>
179 230 </label>
180 231 </fieldset>
181 232 </td>
182 233 </tr>
@@ -181,132 +232,185 @@
181 232 </td>
182 233 </tr>
183 234 <tr>
184 235 <th scope="row">
185 - <label for="validation"><?php echo __('Validation','wpdirectorykit'); ?></label>
236 + <label for="validation"><?php echo esc_html__('Validation', 'wpdirectorykit'); ?></label>
186 237 </th>
187 238 <td>
188 - <?php
189 - echo wmvc_select_option('validation', array_merge(array(''=> __('Not Selected','wpdirectorykit')),$this->field_m->fields_validations), wmvc_show_data('validation', $db_data, ''), 'id="validation"');
239 + <?php
240 + echo wp_kses(
241 + wmvc_select_option(
242 + 'validation',
243 + array_merge(array('' => __('Not Selected', 'wpdirectorykit')), $this->field_m->fields_validations),
244 + wmvc_show_data('validation', $db_data, ''),
245 + 'id="validation"'
246 + ),
247 + array(
248 + 'select' => array(
249 + 'id' => true,
250 + 'name' => true,
251 + 'class' => true,
252 + 'style' => true,
253 + 'multiple' => true,
254 + 'size' => true,
255 + ),
256 + 'option' => array(
257 + 'value' => true,
258 + 'selected' => true,
259 + 'disabled' => true,
260 + ),
261 + )
262 + );
263 +
190 264 ?>
191 265 </td>
192 266 </tr>
193 267 <tr>
268 + <th scope="row">
269 + <label for="autosuggestion"><?php echo esc_html__('Autosuggestion', 'wpdirectorykit'); ?></label>
270 + </th>
271 + <td>
272 + <select name="autosuggestion" id="autosuggestion"
273 + <?php if (!file_exists(ABSPATH . 'wp-content/plugins/wdk-autosuggestion/wdk-autosuggestion.php')): ?>
274 + class="wdk-pro-select"
275 + data-button-success="<?php echo esc_attr__('Purchase Now', 'wpdirectorykit'); ?>"
276 + data-title="<?php echo esc_attr__('Your version doesn\'t support this functionality, please upgrade', 'wpdirectorykit'); ?>"
277 + data-content="<?php echo esc_attr__('We constantly maintain compatibility and improving this plugin for living, please support us and purchase, we provide very reasonable prices and will always do our best to help you!', 'wpdirectorykit'); ?>"
278 + data-action="https://www.wpdirectorykit.com/plugins.html/"
279 + <?php elseif (file_exists(ABSPATH . 'wp-content/plugins/wdk-autosuggestion/wdk-autosuggestion.php') && !function_exists('run_wdk_autosuggestion')): ?>
280 + class="wdk-pro-select"
281 + data-button-success="<?php echo esc_attr__('Activate addon WDK Autosuggestion', 'wpdirectorykit'); ?>"
282 + data-title="<?php echo esc_attr__('Your version doesn\'t support this functionality, please upgrade', 'wpdirectorykit'); ?>"
283 + data-content="<?php echo esc_attr__('We constantly maintain compatibility and improving this plugin for living, please support us and purchase, we provide very reasonable prices and will always do our best to help you!', 'wpdirectorykit'); ?>"
284 + data-action="<?php echo esc_url(get_admin_url() . "plugins.php?plugin_status=all#activate-wdk-autosuggestion"); ?>"
285 + <?php endif; ?>>
286 + <option value=""><?php echo esc_html__('Not Selected', 'wpdirectorykit'); ?></option>
287 + <?php foreach ($this->field_m->fields_autosuggestions as $key => $value): ?>
288 + <option class="<?php if (in_array($key, ['google_api_cities', 'google_api_countries', 'rapid_api_cities'])): ?>pro-value<?php endif; ?>" value="<?php echo esc_attr($key); ?>" <?php echo !empty(wmvc_show_data('autosuggestion', $db_data, '') == $key) ? 'selected="selected"' : ''; ?>><?php echo esc_html($value); ?></option>
289 + <?php endforeach; ?>
290 + </select>
291 + </td>
292 + </tr>
293 + <tr>
194 294 <th scope="row"><label
195 - for="min_length"><?php echo __('Min Length','wpdirectorykit'); ?></label>
295 + for="min_length"><?php echo esc_html__('Min Length', 'wpdirectorykit'); ?></label>
196 296 </th>
197 297 <td>
198 298 <input name="min_length" type="number" id="min_length"
199 - value="<?php echo wmvc_show_data('min_length', $db_data, ''); ?>"
299 + value="<?php echo esc_attr(wmvc_show_data('min_length', $db_data, '')); ?>"
200 300 class="regular-text">
201 301 <p class="description" id="columns_number-description">
202 - <?php echo __('Min Characters or min number (if number field type)','wpdirectorykit'); ?>
302 + <?php echo esc_html__('Min Characters or min number (if number field type)', 'wpdirectorykit'); ?>
203 303 </p>
204 304 </td>
205 305 </tr>
206 306 <tr>
207 307 <th scope="row"><label
208 - for="max_length"><?php echo __('Max Length','wpdirectorykit'); ?></label>
308 + for="max_length"><?php echo esc_html__('Max Length', 'wpdirectorykit'); ?></label>
209 309 </th>
210 310 <td>
211 311 <input name="max_length" type="number" id="max_length"
212 - value="<?php echo wmvc_show_data('max_length', $db_data, ''); ?>"
312 + value="<?php echo esc_attr(wmvc_show_data('max_length', $db_data, '')); ?>"
213 313 class="regular-text">
214 314 <p class="description" id="columns_number-description">
215 - <?php echo __('Max Characters or max number (if number field type)','wpdirectorykit'); ?>
315 + <?php echo esc_html__('Max Characters or max number (if number field type)', 'wpdirectorykit'); ?>
216 316 </p>
217 317 </td>
218 318 </tr>
219 - <?php if(false):?>
319 + <?php if (false): ?>
320 + <tr>
321 + <th scope="row"><?php echo esc_html__('Visible on', 'wpdirectorykit'); ?></th>
322 + <td>
323 + <fieldset>
324 + <legend class="screen-reader-text">
325 + <span><?php echo esc_html__('Visible on', 'wpdirectorykit'); ?></span>
326 + </legend>
327 + <label for="is_visible_frontend">
328 + <input name="is_visible_frontend" type="checkbox" id="is_visible_frontend"
329 + value="1"
330 + <?php echo !empty(wmvc_show_data('is_visible_frontend', $db_data, '')) ? 'checked' : ''; ?>>
331 + <?php echo esc_html__('Frontend', 'wpdirectorykit'); ?>
332 + </label>
333 + <label for="is_visible_dashboard">
334 + <input name="is_visible_dashboard" type="checkbox" id="is_visible_dashboard"
335 + value="1"
336 + <?php echo !empty(wmvc_show_data('is_visible_dashboard', $db_data, '')) ? 'checked' : ''; ?>>
337 + <?php echo esc_html__('Dashboard', 'wpdirectorykit'); ?>
338 + </label>
339 + </fieldset>
340 + </td>
341 + </tr>
342 + <?php endif; ?>
220 343 <tr>
221 - <th scope="row"><?php echo __('Visible on','wpdirectorykit'); ?></th>
222 - <td>
223 - <fieldset>
224 - <legend class="screen-reader-text">
225 - <span><?php echo __('Visible on','wpdirectorykit'); ?></span>
226 - </legend>
227 - <label for="is_visible_frontend">
228 - <input name="is_visible_frontend" type="checkbox" id="is_visible_frontend"
229 - value="1"
230 - <?php echo !empty(wmvc_show_data('is_visible_frontend', $db_data, ''))?'checked':''; ?>>
231 - <?php echo __('Frontend','wpdirectorykit'); ?>
232 - </label>
233 - <label for="is_visible_dashboard">
234 - <input name="is_visible_dashboard" type="checkbox" id="is_visible_dashboard"
235 - value="1"
236 - <?php echo !empty(wmvc_show_data('is_visible_dashboard', $db_data, ''))?'checked':''; ?>>
237 - <?php echo __('Dashboard','wpdirectorykit'); ?>
238 - </label>
239 - </fieldset>
240 - </td>
241 - </tr>
242 - <?php endif;?>
243 - <tr>
244 - <th scope="row"><label for="icon_id"><?php echo __('Icon','wpdirectorykit'); ?></label>
344 + <th scope="row"><label for="icon_id"><?php echo esc_html__('Icon', 'wpdirectorykit'); ?></label>
245 345 </th>
246 346 <td>
247 - <?php
248 - echo wmvc_upload_media('icon_id', wmvc_show_data('icon_id', $db_data, ''));
347 + <?php
348 + // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped, WordPress.WP.I18n.NonSingularStringLiteralText
349 + echo wmvc_upload_media('icon_id', wmvc_show_data('icon_id', $db_data, ''));
249 350 ?>
250 351 <p class="description" id="icon_id-description">
251 - <?php echo __('Icon used for amenities or special places on website','wpdirectorykit'); ?>
352 + <?php echo esc_html__('Icon used for amenities or special places on website', 'wpdirectorykit'); ?>
252 353 </p>
253 354 </td>
254 355 </tr>
255 356 <tr>
256 - <th scope="row"><label for="prefix"><?php echo __('Prefix','wpdirectorykit'); ?></label>
357 + <th scope="row"><label for="prefix"><?php echo esc_html__('Prefix', 'wpdirectorykit'); ?></label>
257 358 </th>
258 359 <td>
259 360 <input name="prefix" type="text" id="prefix"
260 - value="<?php echo wmvc_show_data('prefix', $db_data, ''); ?>"
361 + value="<?php echo esc_attr(wmvc_show_data('prefix', $db_data, '')); ?>"
261 362 class="regular-text">
262 363 <p class="description" id="prefix-description">
263 - <?php echo __('Visible before field value usable in currency like $999','wpdirectorykit'); ?>
364 + <?php echo esc_html__('Visible before field value usable in currency like $999', 'wpdirectorykit'); ?>
264 365 </p>
265 366 </td>
266 367 </tr>
267 368 <tr>
268 - <th scope="row"><label for="suffix"><?php echo __('Suffix','wpdirectorykit'); ?></label>
369 + <th scope="row"><label for="suffix"><?php echo esc_html__('Suffix', 'wpdirectorykit'); ?></label>
269 370 </th>
270 371 <td>
271 372 <input name="suffix" type="text" id="suffix"
272 - value="<?php echo wmvc_show_data('suffix', $db_data, ''); ?>"
373 + value="<?php echo esc_attr(wmvc_show_data('suffix', $db_data, '')); ?>"
273 374 class="regular-text">
274 375 <p class="description" id="suffix-description">
275 - <?php echo __('Visible after field value usable in metrics like 200ft','wpdirectorykit'); ?>
376 + <?php echo esc_html__('Visible after field value usable in metrics like 200ft', 'wpdirectorykit'); ?>
276 377 </p>
277 378 </td>
278 379 </tr>
279 380 <tr>
280 381 <th scope="row"><label
281 - for="values_list"><?php echo __('Values','wpdirectorykit'); ?></label></th>
382 + for="values_list"><?php echo esc_html__('Values', 'wpdirectorykit'); ?></label></th>
282 383 <td>
283 384 <input name="values_list" type="text" id="values_list"
284 - value="<?php echo wmvc_show_data('values_list', $db_data, ''); ?>"
385 + value="<?php echo esc_attr(wmvc_show_data('values_list', $db_data, '')); ?>"
285 386 class="regular-text">
286 387 <p class="description" id="values_list-description">
287 - <?php echo __('Values selectable in dropdown, separate with, like value1,value2,value3','wpdirectorykit'); ?>
388 + <?php echo esc_html__('Values selectable in dropdown, separate with, like value1,value2,value3', 'wpdirectorykit'); ?>
288 389 </p>
289 390 </td>
290 391 </tr>
291 392 <tr>
292 393 <th scope="row"><label
293 - for="empty_value"><?php echo __('Value when empty','wpdirectorykit'); ?></label></th>
394 + for="empty_value"><?php echo esc_html__('Value when empty', 'wpdirectorykit'); ?></label></th>
294 395 <td>
295 396 <input name="empty_value" type="text" id="empty_value"
296 - value="<?php echo wmvc_show_data('empty_value', $db_data, ''); ?>"
397 + value="<?php echo esc_attr(wmvc_show_data('empty_value', $db_data, '')); ?>"
297 398 class="regular-text">
298 399 <p class="description" id="empty_value-description">
299 - <?php echo __('This value will be visible if this field is not populated','wpdirectorykit'); ?>
400 + <?php echo esc_html__('This value will be visible if this field is not populated', 'wpdirectorykit'); ?>
300 401 </p>
301 402 </td>
302 403 </tr>
303 404 </tbody>
304 405 </table>
305 - <input type="submit" name="submit" id="submit" class="button button-primary" value="<?php echo esc_html__('Save Changes','wpdirectorykit'); ?>">
406 + <input type="submit" name="submit" id="submit" class="button button-primary" value="<?php echo esc_attr__('Save Changes', 'wpdirectorykit'); ?>">
306 407 </form>
307 408 </div>
308 409 </div>
309 410 </div>
310 411 </div>
311 -
412 +<?php
413 +wp_enqueue_style('jquery-confirm');
414 +wp_enqueue_script('jquery-confirm');
415 +?>
312 416 <?php $this->view('general/footer', $data); ?>