- $dbhost = ((x($_POST, 'dbhost')) ? notags(trim($_POST['dbhost'])) : 'localhost');
- $dbuser = notags(trim($_POST['dbuser']));
- $dbpass = notags(trim($_POST['dbpass']));
- $dbdata = notags(trim($_POST['dbdata']));
- $phpath = notags(trim($_POST['phpath']));
-
- $adminmail = notags(trim($_POST['adminmail']));
+ $dbhost = notags(trim(defaults($_POST, 'dbhost' , 'localhost')));
+ $dbuser = notags(trim(defaults($_POST, 'dbuser' , '' )));
+ $dbpass = notags(trim(defaults($_POST, 'dbpass' , '' )));
+ $dbdata = notags(trim(defaults($_POST, 'dbdata' , '' )));
+ $phpath = notags(trim(defaults($_POST, 'phpath' , '' )));
+ $adminmail = notags(trim(defaults($_POST, 'adminmail', '' )));