$_SESSION Issue

Rayj00

New member
So after some searching, I found that using $_SESSION to pass a variable from one php page to another would suit my needs.

So here is what I am doing. I have an html form with multiple input.
I generate a jobnumber when the form is sent (submitted). But I want
to save the value of jobnumber for a PHP File 2. The problem is I am not getting
any response from the server in regards to what I am doing in File 1.

PHP File 1:
<?php
session_start();
// some code...
$dndid = $updatejobnumber; // the $updatejobnumber variable initialized a littler earlier in the code
$_SESSION['$dndjobnumber'] = '$dndid';
if (isset($_SESSION['$dndjobnumber'])) {
echo $_SESSION['$dndjobnumber'];
}

Any comments on why this is not working?
PS: I monitor the PHP via the firefox Web Developer Tool and the Netword Response tab.

Here is how I monitor for $_FILES:
echo '<pre>';
echo 'Here is some more debugging info:';
print_r($_FILES);
print "</pre>"; This works fine.

But if I add print_r($_SESSION); after the print_r($_FILES) there is no change?

Comments?

Thanks,

Ray
 
Back
Top