Wie hast Du das denn geprüft?
off:PP
Hallo Peter Pan,
so habe ich es geprüft:
$_expected['postlistepflicht']=array('vorname',
'nachname',
'strasse',
'hausnummer',
'plz',
'ort',
'land',
'telefon',
'fax',
'email',
'email-bestaetigung',
'lala',0,1,2,3,4,5,6,7,8,9,10,
'betreff',
'nachricht',
'checkboxeins',
'checkboxzwei',
'checkboxdrei');
$_expected['allposts']=array_keys($_POST);
foreach($_POST as $elementpost)
{
if (is_array($elementpost))
$_expected['allposts']=array_merge($_expected['allposts'],array_keys($elementpost));
}
$_expectedDif['postlistepflicht']=array_diff($_expected['allposts'],$_expected['postlistepflicht']);
$_expectedDif['allposts']=array_diff($_expected['postlistepflicht'],$_expected['allposts']);
if (count($_expectedDif['postlistepflicht'])>0 OR count($_expectedDif['allposts'])>0)
{
echo "1 stimmt nicht";
print_r($_expectedDif['postlistepflicht']);
}
else
{
echo "1 stimmt";
}
Gruß,
Runtop