-3
Why does this simple form not work in the new Chrome v69? What do I have to add or remove to run again?
<?php
require('conISO.php');
if(isset($_POST['modelo'])){$modelo = $_POST['modelo'];}
if(!empty($_POST['cadastro']))
{
if(empty($modelo))
{$caso = 'modelo';}
else
{
mysql_query("INSERT INTO multimarcas
(MODELO)
VALUES ('$modelo')");
$caso = "sucesso";
}
}
?>
<!DOCTYPE HTML>
<html>
<head>
<title>ERP Smart</title>
</head>
<body>
<form action="TESTE.php" name="cadastro" method="post">
<table >
<tr>
<td>
<?php
if(isset($caso)){
switch($caso){
case "modelo":
echo "Atenção. Falta Modelo!";
break;
case "sucesso":
echo "Parabéns. Produto cadastrado com sucesso!";
break;
}
}
?>
</td>
</tr>
<td >
<input name="modelo" type="text">
</td>
<td >
<input name="cadastro" type="image" src="../img/REG.png" value="1">
</td>
</tr>
</table>
</form>
</body>
</html>
Welcome to the web world. People think it’s easier to do in this environment, what a mistake...
– Maniero