Register  |  Login



Earn money by sharing your knowledge through Quomon's revenue sharing program

Question

Status: Open Points: 200 Time: 19:58 - Aug 26, 2008  

gloria_g

php, session variable not passed

Hi, Dude,

Here is my website:
http://cookword.com

Problem:

When the user login, ( login page: http://cookword.com/index.php, username: gloria, password: 123456789) user data is transfered to:
http://recipeyeh.com/users/users_login_c...
for validation. Upon success, the page is redirected to original page: http://cookword.com/index.php.

However, the username and other info variables are not passed to http://cookword.com/index.php.

Could you login to my website and have a look if something is wrong? I will you give you login info if you are willing to help. Thanks.

Sincerely,

Gloria

Answer Discussion
Tutorials

 

Q&A System for Websites and Corporate Collaboration

Advertisement

  • Generates significant organic traffic for websites
  • Saves companies money, resources, and time

shashi.programmer

Date:: Aug 27, 2008

Time:: 01:56

<?
// this is for login verification page

session_start(); // start session here
include "connection.php"; // connection file include for database
$username=$_REQUEST['username']; // username pass from username textbox
$password=$_REQUEST['password']; //password pass from password textbox
$sql="select * from tablename where username='$username' and password='$password'"; // query from registration table where user data is available
$result=mysql_query($sql);
mysql_num_rows($result);
if(mysql_num_rows($result)>0)
{
 $row=mysql_fetch_array($result);
 $_SESSION['id']=$row['id'];
 echo "<script>location.href='success.php'</script>"; // redirect the browser after successful login
 
}
else
{
 echo "<script>location.href='login.php?Err=Incorrect Username or Password'</script>"; // redirect the browser after invliad login or password insert
}

// end of the login verification page





// start of the each and every page you have to put up following information

session_start(); // start the session
$id=$_SESSION['id']; // this will carry the particular user's id

?>

gloria_g

Date:: Aug 27, 2008

Time:: 13:43

Hi, Shashi,

Would you like to login into my web site server and have a look what is wrong. If yes, please send me an email or post your email address here, I will give you the username and password. Thanks,

My email: gloriabai@yahoo.com

Sincerely,

Gloria

Answer this Question

New User

Email:

Upon submission of this form, you will automatically be registered as a Quomon user and we will send your login information to this address

Registered User

Username:

Password:

Forgot Your Password?

Tutorials cannot be submitted until the Answer Discussion is complete.

Submit answers in the Answer Discussion area

Ask a Question

Have a new question? Ask!

You have 100 characters to use



Top Experts

View More

Rank

Expert

Points

1.

nidhi

6432

2.

rcastagna

4221

3.

LAGM

3650

4.

PeterNZ

2807

5.

oracleofDelphi

2698

6.

jgivoni

1953

7.

xarcus

1820

8.

gonzalo

1000

9.

Anpanman

812

10.

theDude

695

Become an Expert

Register today to share your knowledge with the community and be recognized and rewarded for your contributions.


Register Here




"Psst, Quomon is a great site. Pass it on."     Tell a Friend  |   Link To Us  |   Save to Delicious  |   Digg! Digg it



Language Options

English:

www.quomon.com

Español:

www.quomon.es