I have a problem, I need to receive data (just one string from a form, it’s a name what it receives):
$received_data = $_POST['data'];
$ip = checkip();
And the ‘user’ IP (it not needs cookies or session and I can’t use them), I must to save both datas (data and ip) on a database and allow to see 5 per hour, but allow to see the same that already saw, I mean the ‘data’ stored on database can see without limit, but only 5 differents datas (names) per hour, for example:
Can check: Martha, Jack, Lily, Mark and Peter (per hour, and the next hour can check others or maybe the same – depens on user).
And in the same hour can check the five names already checked, but not other til the next hour.
And if try to check Martha, Jack and then Martha again, (the second Martha) not counts, because it’s already checked in the same hour.
I don’t know how can I do it, could anybody help me?
Thank you in advanced, kind regards.
1 Answer