注意:未定义的变量:第38行的C:\ wamp \ www \ public \ index.php中的router_address

时间:2018-05-09 15:19:57

标签: php mysql

我得到这样的错误: 注意:未定义的变量:第38行的C:\ wamp \ www \ public \ index.php中的router_address 我不明白为什么即使一切似乎都是正确的 请帮忙

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');
  }
}
}

0 个答案:

没有答案