Jump to content

Warning message when I try tor register


mariocesar

Recommended Posts

The script was working fine, I changed the hosting Co, now I think is php 5, here is the message:

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

[code]<?

if ($_POST[user] && $_POST[pass]) {

      $db = mysql_connect('*****', $user = "****", $pass = "***" );

mysql_select_db("copymailregister", $db);



$result = mysql_query ("SELECT * FROM usersreg WHERE name = '".$_POST[user]."'");

if (mysql_num_rows($result) == 0) {



$result = mysql_query ("INSERT INTO usersreg (name, password, company, email, address, city, state, zipCode) VALUES

('".$_POST[user]."', PASSWORD('".$_POST[pass]."'),'".$company."', '".$email."', '".$address."', '".$city."', '".$state."', '".$zipCode."')");

if ($result) {





$logged_in_user = $_POST[user];

session_register("logged_in_user");

echo "<div class='templine'>Your details have been added to the database, ".$_POST[user]."<BR><BR>";

echo "<div class='powerftp'><img src='images/arrow2.gif'>&nbsp;&nbsp;<A HREF='main.php'>My Account</A></div><BR>";
echo "<div class='powerftp'><img src='images/arrow2.gif'>&nbsp;&nbsp;<A HREF='logout.php'>logout</A></div>";
       

exit;

} else {

echo "<div class='templine'>Sorry, there has been a technical hitch. We cannot enter your details.</div>";

exit;

}

} else {



echo "<div class='templine'>Sorry, that username has been taken. Please try another.<BR></div>";

}

} else if ($_POST[user] || $_POST[pass]) {



echo "<div class='templine'>Please fill in all fields..</div>";

}

?>[/code]

Thanks.

(edited by kenrbnsn to remove db login info)
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.