check posted parameters
This commit is contained in:
parent
fc44c9a7f4
commit
ce89118713
30
install.php
30
install.php
|
@ -130,6 +130,36 @@ function handlePost()
|
|||
$password = $_POST['password'];
|
||||
$sitename = $_POST['sitename'];
|
||||
|
||||
if (empty($host)) {
|
||||
updateStatus("No hostname specified.", true);
|
||||
showForm();
|
||||
return;
|
||||
}
|
||||
|
||||
if (empty($database)) {
|
||||
updateStatus("No database specified.", true);
|
||||
showForm();
|
||||
return;
|
||||
}
|
||||
|
||||
if (empty($username)) {
|
||||
updateStatus("No username specified.", true);
|
||||
showForm();
|
||||
return;
|
||||
}
|
||||
|
||||
if (empty($password)) {
|
||||
updateStatus("No password specified.", true);
|
||||
showForm();
|
||||
return;
|
||||
}
|
||||
|
||||
if (empty($sitename)) {
|
||||
updateStatus("No sitename specified.", true);
|
||||
showForm();
|
||||
return;
|
||||
}
|
||||
|
||||
updateStatus("Starting installation...");
|
||||
updateStatus("Checking database...");
|
||||
$conn = mysql_connect($host, $username, $password);
|
||||
|
|
Loading…
Reference in New Issue
Block a user