mi sa che in questo $_POST ci entra proprio 'action' che però è il nome del tasto submit
if(isset($_POST['action']) and ($_POST['action'] == 'Invia')){
$ret = reg_check_data($_POST);
$status = ($ret === true) ? reg_register($_POST) : REG_ERRORS;
ma nello script di sola registrazione non accade!!
function reg_check_data(&$data){
global $_CONFIG;
$errors = array();
foreach($data as $field_name => $value){
$func = $_CONFIG['check_table'][$field_name];
if(!is_null($func)){
$ret = $func($value);
if($ret !== true)
$errors[] = array($field_name, $ret);
}
}
return count($errors) > 0 ? $errors : true;
}
come posso risolvere?