PluginProbe
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress / 11.1.0
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress v11.1.0
11.1.1 11.1.0 11.0.5 11.0.4 11.0.3 11.0.2 11.0.1 11.0.0 10.11.1 10.11.0 10.10.2 10.10.1 10.10.0 10.9.1 trunk 10.0.0 10.0.1 10.1.0 10.1.1 10.1.2 10.1.3 10.1.4 10.2.0 10.2.1 10.2.2 All 62 releases
← All changes | back/Views/Users/tmpl/importfromdatabase.php +17 -9 10.0.1 → 11.1.0 View file →
@@ -1,12 +1,16 @@
1 +<?php
2 +// phpcs:disable WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- View file, its variables are local to the include scope, not true globals.
3 +defined('ABSPATH') || die('Restricted Access');
4 +?>
1 5 <div id="acym__users__import__from_database" class="grid-x padding-vertical-2 padding-horizontal-2">
2 6 <div class="cell large-3"></div>
3 7 <div class="cell large-6 grid-x margin-y">
4 - <label class="cell medium-4" for="acym__users__import__from_database__field--tablename"><?php echo acym_translation('ACYM_TABLE_NAME'); ?></label>
8 + <label class="cell medium-4" for="acym__users__import__from_database__field--tablename"><?php echo esc_html(acym_translation('ACYM_TABLE_NAME')); ?></label>
5 9 <?php
6 - echo '<div class="cell medium-8">';
10 + echo '<div class="cell medium-8">';
7 11 array_unshift($data['tables'], acym_translation('ACYM_SELECT_TABLE'));
8 - echo acym_select(
12 + acym_select(
9 13 $data['tables'],
10 14 'tablename',
11 15 null,
12 16 [
@@ -13,9 +17,11 @@
13 17 'class' => 'acym__select',
14 18 ],
15 19 'value',
16 20 'name',
17 - 'acym__users__import__from_database__field--tablename'
21 + 'acym__users__import__from_database__field--tablename',
22 + false,
23 + true
18 24 );
19 25 echo '</div>';
20 26
21 27 $userFields = acym_getColumns('user');
@@ -21,11 +27,13 @@
21 27 $userFields = acym_getColumns('user');
22 28 if (!empty($userFields)) {
23 29 foreach ($userFields as $oneUserField) {
24 30 if (!in_array($oneUserField, ['id', 'key', 'automation'])) {
25 - echo '<label class="cell medium-4" for="acym__users__import__from_database__field--'.$oneUserField.'">'.$oneUserField.'</label>';
31 + echo '<label class="cell medium-4" for="acym__users__import__from_database__field--'.esc_attr($oneUserField).'">'.esc_html($oneUserField).'</label>';
26 32 echo '<div class="cell medium-8">';
27 - echo '<select acym-data-infinite class="acym__users__import__from_database__fields acym__select" name="fields['.$oneUserField.']" id="acym__users__import__from_database__field--'.$oneUserField.'"></select>';
33 + echo '<select acym-data-infinite class="acym__users__import__from_database__fields acym__select" name="fields['.esc_attr(
34 + $oneUserField
35 + ).']" id="acym__users__import__from_database__field--'.esc_attr($oneUserField).'"></select>';
28 36 echo '</div>';
29 37 }
30 38 }
31 39 }
@@ -30,17 +38,17 @@
30 38 }
31 39 }
32 40 if ($this->config->get('require_confirmation')) { ?>
33 41 <div class="cell grid-x">
34 - <?php echo acym_switch('import_confirmed_database', 1, acym_translation('ACYM_IMPORT_USERS_AS_CONFIRMED')); ?>
42 + <?php acym_switch(['name' => 'import_confirmed_database', 'value' => 1, 'label' => acym_translation('ACYM_IMPORT_USERS_AS_CONFIRMED')]); ?>
35 43 </div>
36 44 <?php } ?>
37 45
38 46 <div class="cell grid-x grid-margin-x">
39 47 <div class="cell hide-for-small-only medium-auto"></div>
40 - <?php echo acym_cancelButton('ACYM_CANCEL', '', 'button medium-6 large-shrink margin-bottom-0'); ?>
48 + <?php acym_cancelButton('ACYM_CANCEL', '', 'button medium-6 large-shrink margin-bottom-0'); ?>
41 49 <button type="button" class="button cell medium-shrink margin-bottom-0" data-open="acym__user__import__add-subscription__modal" data-from="database">
42 - <?php echo acym_translation('ACYM_IMPORT'); ?>
50 + <?php echo esc_html(acym_translation('ACYM_IMPORT')); ?>
43 51 </button>
44 52 <button id="submit_import_database" class="acym__import__submit is-hidden" data-from="database"></button>
45 53 <div class="cell hide-for-small-only medium-auto"></div>
46 54 </div>