<body>
<form action="" method="get">
<table width="301" height="104" border="1">
<tr>
<td>user</td>
<td><label>
<input type="text" name="user" />
</label></td>
</tr>
<tr>
<td>passwd</td>
<td><label>
<input type="password" name="passwd" />
</label></td>
</tr>
</table>



<label>
<input type="submit" name="Submit" value="Invia" />
</label>
</p>
</form>

<?php
mysql_connect ('','','') or die ('Connessione non avvenuta');
mysql_select_db ('utenti') or die ('Problemi a connettermi al database');
$insert = "INSERT INTO utenti VALUES (NULL, '$_GET[user]', '$_GET[passwd]')";
$result = mysql_query ($insert);
?>
</body>
</html>

Notice: Undefined index: user in C:\site\ospiti.php on line 34

Notice: Undefined index: passwd in C:\site\ospiti.php on line 34


Ciao a tutti. Una volta lanciato questo script ottengo degli errori dove sei dice che nessun valore e' stato passato alle 2 variabili. Come posso evitare tutto questo? Grazie