i get this kinda error: Notice: Undefined variable: router_address in C:\wamp\www\public\index.php on line 38 and i don't understand why even though everything seems right please help
require_once'connection.php';
if(isset($_POST['send']))
{
$routername = trim($_POST['routername']);
$router_brand = trim($_POST['router_brand']);
$router_type = trim($_POST['router_type']);
if (isset($_POST['router_address'])) {$router_address =
$_POST['router_address']; }
if($routername=="") {
$error[] = "provide router name !";
}
elseif($router_brand=="") {
$error[] = "provide router brand !";
}
elseif( $router_type=="") {
$error[] = "provide router type !";
}
elseif($router_address=="") {
$error[] = "provide router address !";
}else
{
if($router->register($routername,$router_brand,$router_type,$router_address))
{
$router->redirect('index.php?joined');
}
}
}