summaryrefslogtreecommitdiff
path: root/views/admin/laender.phtml
diff options
context:
space:
mode:
Diffstat (limited to 'views/admin/laender.phtml')
-rw-r--r--views/admin/laender.phtml47
1 files changed, 37 insertions, 10 deletions
diff --git a/views/admin/laender.phtml b/views/admin/laender.phtml
index 6c91a39..89e2d0c 100644
--- a/views/admin/laender.phtml
+++ b/views/admin/laender.phtml
@@ -37,6 +37,8 @@
<form name="form1" method="post" enctype="multipart/form-data" action="<?php echo wpsg_hspc(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&noheader=1'); ?>">
+ <?php echo wp_nonce_field('wpsg-admin-laender'); ?>
+
<?php echo wpsg_drawForm_AdminboxStart(__('Länderverwaltung', 'wpsg')); ?>
<div id="wpsg_country_list">
@@ -63,13 +65,16 @@
function wpsg_country_check_all() { jQuery('td.col_check input').each(function() { jQuery(this).prop('checked', !jQuery(this).prop('checked')); } ); }
- function wpsg_country_remove(land_id)
- {
+ function wpsg_country_remove(land_id) {
if (!confirm('<?php echo __('Sind Sie sich sicher?', 'wpsg'); ?>')) return false;
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=remove&noheader=1',
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=remove&noheader=1', 'wpsg-laender-delete'));
+
+ ?>',
data: {
land_id: land_id
},
@@ -92,7 +97,11 @@
jQuery('#Modal_wpsg_country_edit').modal('show');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=add&noheader=1',
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=add&noheader=1', 'wpsg-laender-add'));
+
+ ?>',
success: function(data) { jQuery('#Modal_wpsg_country_edit .modal-body').html(data); }
} );
@@ -100,15 +109,18 @@
} // function wpsg_country_add()
- function wpsg_country_import()
- {
+ function wpsg_country_import() {
if (!confirm('<?php echo __('Sind Sie sich sicher?', 'wpsg'); ?>')) return false;
jQuery('#wpsg_country_list').html('<img src="<?php echo $this->getRessourceURL('gfx/ajax-loader.gif'); ?>" alt="" />');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=import&noheader=1',
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=import&noheader=1', 'wpsg-laender-import'));
+
+ ?>',
success: function(data) {
jQuery('#wpsg_country_list').html(data);
@@ -128,7 +140,11 @@
jQuery('#wpsg_country_list').html('<img src="<?php echo $this->getRessourceURL('gfx/ajax-loader.gif'); ?>" alt="" />');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=eu_import&noheader=1',
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=eu_import&noheader=1', 'wpsg-laender-eu_import'));
+
+ ?>',
success: function(data) {
jQuery('#wpsg_country_list').html(data);
@@ -146,7 +162,11 @@
jQuery('#wpsg_country_list').html('<img src="<?php echo $this->getRessourceURL('gfx/ajax-loader.gif'); ?>" alt="" />');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=save&noheader=1',
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=save&noheader=1', 'wpsg-laender-save'));
+
+ ?>',
data: {
form_data: jQuery('#wpsg_land_edit_form_edit').serialize()
},
@@ -166,7 +186,14 @@
jQuery('#Modal_wpsg_country_edit').modal('show');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=edit&noheader=1&land_id=' + land_id,
+ url: '<?php
+
+ echo html_entity_decode(wp_nonce_url(WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&subaction=laender&do=edit&noheader=1', 'wpsg-laender-edit'));
+
+ ?>',
+ data: {
+ land_id: land_id
+ },
success: function(data) { jQuery('#Modal_wpsg_country_edit .modal-body').html(data); }
} );