Hello all,
I am a relative newbie to php so bear with me.
2 questions. If you can help with either I would be very greatful.
I have attached the page in question so you can see the code.
I know the page is ugly but I am trying to get it working before
I clean and comment it.
1st: I am building an Authorization only area for employees in my company to use for customer management.
Well, everything is going fine except when I added a link to log out a user and show the login screen again, something doesn't refresh correctly. If you click logout only half of the login page comes back up (and not the form part to log in with). but if you hit the refresh button, it comes back fine. I use sessions to track users if that helps. Anyone know how to fix this?
2nd: can someone tell me how or give me a link to a place where I can see how to send a PHP_SELF link in an anchor tag? Right now I need to use a form submit button but that doesn't look very good. I want to pass a variable through this link (I.E. I want to destroy the session) and then have the page refresh. I'll give you the form (and function) code for it so you can see what I mean.
<form method=post action="<?echo $PHP_SELF?>">
<input type="submit" name="destroy" value="Log out">
</form>
<?php
if ($destroy) {
session_destroy();
}
?>