[SOLVED] Checking if user already exists????
Posted: Sun Jun 20, 2004 5:00 am
Why this script doesnt work?
I get warning:
"Warning: Unknown(): Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this functionality and this warning by setting session.bug_compat_42 or session.bug_compat_warn to off, respectively. in Unknown on line 0"
and script is:
I get warning:
"Warning: Unknown(): Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this functionality and this warning by setting session.bug_compat_42 or session.bug_compat_warn to off, respectively. in Unknown on line 0"
and script is:
Code: Select all
<?php
session_start();
?>
<?php
include("con_db.php");
mysql_select_db("iznajmljivaci") or
die("Nije moguæe pristupiti bazi podataka");
/* provjera dali ulaz veæ postoji */
$sel = "SELECT email FROM iznajmljivaci where email = '$email'";
$quer = mysql_query($sel);
$row = mysql_fetch_array($quer);
$email = $_SESSION['email'] = $row["email"];
// check if email exist
if ($email == "") {
//insert into database;
} else {
echo "e-mail already exists";
}
?>
?>