I already know how to pass a variable to a single page or post. However, I do not know how to pass the variable to a different page or post. For example, if the user goes to this URL:
Then, in post1 I can call on myvariable. However, if the user then clicks on another post or page, I do not know how to pass myvariable to the outgoing page/post. I tried using a session_id as described here:
but myvariable is not stored and not passed from page to page or post to post. I even tried putting the following code in my theme's header file.
<br /> session_start();<br /> if(isset($_SESSION['myvariable']))<br /> $_SESSION['myvariable'] = $_SESSION['myvariable'];<br /> else<br /> $_SESSION['myvariable'] = $_GET['myvariable'];<br />
Can someone please help me. I been trying to get this to work for awhile.