How reliable is passing variables in SESSION w/ PHP
<p>How reliable is a method of setting variables into a session and then retrieving them on another page?</p>

<p>I have a script where users drag and drop elements on a page utilizing jQuery UI. I record transactions using AJAX, however, sometimes I get results missing project ID, or to be exact I get 0. I set this ID into a session variable when users first get on this script page. The page has an included JS file with my functions and from there the transaction data is sent to an AJAX page where I store transactions into my db. Because the project ID is the same I get it from my session. It is not a consistent error, happens only once in a  while, but it bothers me a lot. </p>

<p>Why is it happening randomly? And how can I fool-proof my code?</p>

<hr>

<p>UPDATE: OK, it seems it's something else that may be interfearing with that particular session ID.</p>

<p>I do have <code>session_start();</code> on every page where I use sessions and I set them the same way I set all my sessions: `$_SESSION['project'] = $projectID;</p>

<p>Back to debugging...</p>
