php - Saving a USER preference variable after logout -


in project need save information user if has submitted form. doing saving in $_session[] variable when user submit form saved in session variable , writing if(!isset($_session['page'])) restrict user visiting page when logout whole session destroyed. once again able register user has register, how block user re-registering form

this form when form submitted set $_session['personal_datas']=1;

when user revisit form after submittingform after submitting

i check

 <?php if(!isset($_session['personal_datas'])): ?>       //display form   <?php else: ?>     <div class="well">      have submitted form    </div>   <?php endif; ?> 

but when logout revisit page displays same unfilled formenter image description here

how block user re-registering after re-login?

if there unique user enters form (such username or personal identification number) store in database , every time form submitted check username (or whatever) provided not in database.

otherwise there no way of permanently blocking user submitting form again. coockies can deleted (and browser specific). ip-adresses not constant , many users can have same ip.


Comments

Popular posts from this blog

c# - Better 64-bit byte array hash -

webrtc - Which ICE candidate am I using and why? -

php - Zend Framework / Skeleton-Application / Composer install issue -