I am having a little trouble with a session. Not sure if it is my browser or what. I know I do not have any trouble logging into forums such at these, so not sure why this is not working.
first the code. Just basic code from php documentation plus some added checks.
Code: <?php
// page1.php
if (session_start()) {
echo "OK";
} else {
echo "FAIL";
}
// echo phpinfo();
// echo getcwd();
echo 'Welcome to page #1';
$_SESSION['favcolor'] = 'green';
$_SESSION['animal'] = 'cat';
$_SESSION['time'] = time();
print_r($_SESSION);
// Works if session cookie was accepted
echo '<br /><a href="page2.php">page 2</a>';
// Or maybe pass along the session id, if needed
echo '<br /><a href="page2.php?' . SID . '">page 2</a>';
?>
And
Code: <?php
// page2.php
session_start();
echo 'Welcome to page #2<br />';
echo $_SESSION['favcolor']; // green
echo $_SESSION['animal']; // cat
echo date('Y m d H:i:s', $_SESSION['time']);
print_r($_SESSION);
// You may want to use SID here, like we did in page1.php
echo '<br /><a href="page1.php">page 1</a>';
?>
There is no reason why this should not work. Can someone go to:
http://www.e-sullivan.com/DIITop25/page1.php
and tell me if it works for you? It shows me that the sessions are being started but the variables are not passing between page1.php and page2.php for me.
What am I missing here? Help!
Hello all!. I can't seem to get this working right. Well - it renders right, but something is going wrong. It's a set of filters for events. The filter marked "type" (category) works
Looking for help on using joining mysql tables and php....
Does anyone have any good links to references on how to pull mysql data, through joining tables and how one can use php to handle the results? I need some solid clear examples to get me going in the
Inserting into MySQL Newbie
Hi ive got a slight problem where ive made a simple web form where the customer inserts the ammount of tickets and then enters their personal details... then this form does the post method and it then
need to add "sizes" to shopping cart
Hey guys, I am trying to figure out a way to add a "size" selector on to this bit of code. I added a way to view it in the "zoom.php" page and also to select a size from the sizes
Convert Binary String to Decimal
Trying to Get:Decimal: 305419896Out of:Binary String: xV4
Passing JS to PHP
So I have the followingCode: <?phpgetdetails(?><script type="text/javascript">document.write(jsvariable)</script><?php );?>The idea is
Refining of search Criteria
Dear FriendsI need a help, I have a search page which of cars related, which has different search criteria e.g. maker, model, color, displacement etc. when i give any search criteria and click the
Help with PHP and checkboxes
I am posting this for a friend of mine, i wrote a small script for her to process her form data to an email but in testing i am having trouble getting the checkbox data to display in the email it
Please help understand this code
I noticed the index page on my site was modified this morning and found this code inserted at the bottom of the page:Code: <!--ddgbsre_erd_sdd--><?php
upload photo limits
ive got a upload photo script and im just trying to make more secure currently it limits size and as you can see from my code below it limits only gif and php fileshow do i edit my code to limit all