Protecting a form posting to self (takes user back to login)

Started by Leo, February 07, 2013, 09:57:18 AM



And thanks for an awesome script.

I recently had a problem with adding protection to a simple page with form that posts to self.

1. Original form worked smoothly
2. Adding password protection to it was a success (at least almost, because:)
3. when the form is submitted: instead of processing the form, the logged in user is taken back to login prompt.

What would be the way to fix this?

(if it's any help, the protected form is processed like this)
<form name="form1" method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>" >

Any thoughts?