Run a PHP postback request on a page only once? -


I would like to know whether PHP is the equivalent of IsPostBack after the user logs in, I want to call the function or a method only once.

I have a Facebook application, in which the user should enter his details in the database once the application is authorized by the user. This original post should be done using official callback url which is Facebook ping when the user first authorizes the app.

The problem is that since I see that the user is present or not in index.php, I do not like index.php to run this code repeatedly for the same user The user goes to the homepage every time.

Is there a PHP code that will run only once?

  & lt; Input type = "submit" value = "submit" name = "submit_button" /> & Lt ;? Php if (isset ($ _ POST ['submit_button'])) {// if postback only}? & Gt;  

Comments