Jump to content

How to solve Session


inspire

Recommended Posts

Friend....I am using php version 4.0.5 in windows . My problem is i cannot pass

the session from the page1.php to page2.php.

 

note: i am using $HTTP_SESSION_VARS because the php ver <4.1 not support $_SESSION.

 

So how to solve the problem.....pls help 

 

 

page1.php

 

<?php

session_start();

?>

 

<?

//session_register('xyz');

$HTTP_SESSION_VARS['name']="xyz";

?>

 

<html>

<head>

<form action="page2.php" method="post">

<body>

  <input type="Submit" name="login" value="login">

  <input type="input" name="login" >

  </head>

</form>

</body></html>

 

 

page2.php

 

<?php

session_start();

//echo $HTTP_SESSION_VARS['name'];

 

$name=$HTTP_POST_VARS['login'];

 

//echo $login;

?>

Link to comment
https://forums.phpfreaks.com/topic/70088-how-to-solve-session/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.