So, from the beginning: nothing is in my database yet.
I go to the site, register perfectly fine. My name and class are written down in a DB, also my 'controle' character got set to 1. This means that the next time I visit the page, I shouldn't be able anymore to go to it and I should be redirected to '/ingeschreven.php'
So let's say that 'Tom Tollenaere' '6IICT' and '1' are written down in the DB
So basicly, when I revisit the site, I shouldn't be able to do it anymore. This is not the case. I can still visit it
But after that I register another person into the database, as described above, with the following values: 'test jan' '6EE' '1'
Now when I re-go to the site with either logged in as Tom Tollenaere or as test jan or as any new user, it does redirect me to /ingeschreven.php
So it doesn't work, it just doesn't redirect me if I only registered one person, and it redirects me every time after I registered 2 persons...
It should be individual for every person, so if person X has been there before, he shouldn't be able to visit it again, but if person Y is new, he should be able to visit it till he registered himself...
I hope this helped you