<form id="frm" name="frm" method="POST" action="register.php">
<span>Login</span><input type="text" name="nick" value="nick">
<span>Heslo</span><input type="password" name="heslo">
<button type="submit" value="odeslat" name="odeslat">
</form>
<?php
include "config.php";
session_start();
$sql=mysql_query ("SELECT ID_USER FROM tbluser WHERE nick = "$_POST['nick']"");
$num_rows = mysql_num_rows($sql);
if (isset($_POST['nick']) && isset($_POST['heslo']))
{
if($num_rows == 1)
echo "Uživatel existuje";
else
{
mysql_query("INSERT INTO tbluser(`nick`, `heslo`) VALUES
('$_POST['nick']', '".md5($_POST['heslo'])."')");
echo "Registrace Dokončena.";
}
}
?>
Zdravim, hlásí mi to chybu na devátém a desátém řádku, může někdo poradit? děkuji :)