I have this at the top of my page:
<?php
//start session
session_start();
print_r($_SESSION);
?>
then the html below.
It doesn't actually print out the $_SESSION array and I am assuming that is because the html is overriding it and that is ok.
But I want to use show the $_SESSION['username'] as an input value in a form.
<label for="obsName">Observer's Name:</label>
<input type="text" name="ObsName" class="form-control" id="obsName" value="<?php echo $_SESSION['username'];?>">
I use this and what is being shown in the box is just that:
<?php echo $_SESSION['username'];?>
How can I fix this?