Creating form and trying to carry variables accross two pages to a results page. I have tried $GET and $POST and it works fine from page1.php to results.php, but when I change to $SESSION the variable isn't passed or echo'd on results.php. Here's the php code for page1 which won't even work directly to results! Not sure if there is a problem with my code or possibly the server? Page 1.php:
<?php session_start();?>
<?php
$name = $_SESSION['name'];
?>
<FORM action="results.php" method="post" enctype="multipart/form-data" id="questionnaire">
<input type="text" name="name" id="name" />
Results.php:
<?php session_start();?>
<html>
<body>
<?php
$name = $_SESSION['name'];
echo $name; ?>
</body>
</html>