displayCode();
return << $sessionDisplay Einige Pflichtfelder (unterstrichen ' .
'dargestellt) sind nicht ausgefüllt. Email erfolgreich versandt.Kontakt mit ...
';
// einige Pflichtfelder sind nicht ausgefuellt
if (array_key_exists('cn', $_POST) && array_key_exists('ct', $_POST)
&& array_key_exists('cb', $_POST)
&& ! ($_POST['cn'] && $_POST['cb'] && $_POST['ct']))
{
$c['main'] .= throwMissingFields();
}
// Mail verarbeiten
else if (array_key_exists('cmode', $_POST) && $_POST['cmode'] == 's') {
// Pflichtfelder gesetzt?
if (! ($_POST['cn'] && $_POST['cb'] && $_POST['ct'])) {
$c['main'] .= throwMissingFields();
}
else {
$s = new StoredQuizSession();
if ($s->validate()) {
$s->cleanup();
if (! $_POST['cm'])
$_POST['cm'] = MAIL_DEFAULT_FROM;
if (sendMail($_POST['cn'], $_POST['cm'],
MAIL_TO, $_POST['cb'], $_POST['ct']))
{
$c['main'] .= '
Sie haben ' . 'die Sicherheitsfrage falsch ' . 'ausgefüllt.
' . contactForm($s, $name, $mail, $betr, $text); } } } // Formular aufrufen zum Mail verfassen else { $s = new QuizSession(); // ganz simpler Spamschutz $to = str_replace(array('@', '.', '-', '_'), // search array(' ät ', ' punkt ', ' minus ', ' unterstrich '), // replace MAIL_TO); $c['main'] .= <<