<?php session_start();?> <a href="abc.php?color=red"> send the color </a> <br><br> <?php @$_SESSION['color'] = $_GET['color']; echo $_SESSION['color']; ?> <br> <br> <a href="abc.php"> check the session variable </a>
hi, i need help for the above code.
i want to pass a variable to session.
with above code im doing this but the session variable dissappears when i refresh the page or when i click the bottom link. i want the echo $_SESSION['color'];
sticky
what should i do? with regards