diff --git a/includes/frontend-form.php b/includes/frontend-form.php
index c99d774..320921e 100644
--- a/includes/frontend-form.php
+++ b/includes/frontend-form.php
@@ -4,10 +4,6 @@ add_shortcode('konficastle_workshopwahl', function($atts) {
$wahl_id = intval($atts['wahl']);
global $wpdb;
- // Enqueue client-side validation JS
- add_action('wp_footer', function() {
- echo '';
- });
// KRITISCHER TEST: Ausgabe ganz am Anfang
//$debug_output = '
';
@@ -20,7 +16,7 @@ add_shortcode('konficastle_workshopwahl', function($atts) {
$wahl = $wpdb->get_row($wpdb->prepare("SELECT * FROM {$wpdb->prefix}kc_wahlen WHERE id=%d", $wahl_id));
if(!$wahl || !$wahl->freigegeben) {
- return $debug_output . '
';
+ return $debug_output . '
';
}
// Ermittle erlaubte Workshops pro Phase für diese Wahl.
@@ -282,17 +278,8 @@ add_shortcode('konficastle_teamer_create', function($atts) {
} else {
$pw = trim($_POST['kc_teamer_pw'] ?? '');
$saved_hash = get_option('kc_teamer_password_hash', '');
- $valid_pw = false;
- if (!empty($saved_hash)) {
- if (password_verify($pw, $saved_hash)) {
- $valid_pw = true;
- } else if (function_exists('wp_check_password') && wp_check_password($pw, $saved_hash)) {
- // Rückwärtskompatibilität: alter Hash
- $valid_pw = true;
- }
- }
- if (!$valid_pw) {
- $msg = '
Falsches Passwort.
';
+ if (empty($saved_hash) || !wp_check_password($pw, $saved_hash)) {
+ $msg = '
Falsches Passwort.
';
} else {
$vorname = sanitize_text_field($_POST['vorname'] ?? '');
$nachname = sanitize_text_field($_POST['nachname'] ?? '');