Hallo,
ich habe ein Mailformular bei welchem das Formular wieder automatisch mit den Inhalten durch Variablen gefüllt wird wenn der Validator einen Fehler ausgibt.
Nur beim Textfeld funktioniert das nicht. Hier eine abgespeckte Variante des Formulars:
hat jemand eine Idee warum das nicht funktioniert?
Viele Grüße
ich habe ein Mailformular bei welchem das Formular wieder automatisch mit den Inhalten durch Variablen gefüllt wird wenn der Validator einen Fehler ausgibt.
Nur beim Textfeld funktioniert das nicht. Hier eine abgespeckte Variante des Formulars:
PHP:
form method="post" class="mailform">
<?php if($alert): ?>
<div class="alert">
<h3><?php echo l::get('warning')?></h3>
<button type="button" class="unloadalert btn btn-default-white pull-right"><i class="icon-cross"></i></button>
<ul>
<?php foreach($alert as $message): ?>
<li><?php echo html($message) ?></li>
<?php endforeach ?>
</ul>
</div>
<?php endif ?>
<div class="form-group col-xs-24 col-sm-24 col-md-24 col-lg-24">
<label for="name" class="sr-only"><?php echo l::get('name') ?></label>
<input type="text" id="name" class="form-control" name="name" placeholder="<?php echo l::get('name') ?>" value="<?php if (isset($_POST['name'])) : echo $_POST['name']; else: ''; endif ?>">
</div>
<textarea id="text" name="text" class="form-control" rows="6" placeholder="<?php echo l::get('text') ?>" value="<?php if (isset($_POST['text'])) : echo $_POST['text']; else: ''; endif ?>"></textarea>
<div class="form-group col-xs-24 col-sm-24 col-md-24 col-lg-24">
<button class="reset btn btn-red col-xs-11 col-sm-11 col-md-11 col-lg-11 pull-left" type="reset" name="reset" ><?php echo l::get('reset') ?></button>
<button class="submit btn btn-green col-xs-11 col-sm-11 col-md-11 col-lg-11 pull-right" type="submit" name="contactsubmit" value="Submit"><?php echo l::get('submit') ?></button>
</div>
</form>
hat jemand eine Idee warum das nicht funktioniert?
Viele Grüße