Hello! Tell me how can I open access to a specific page of the site, once every 3 hours by ip?

Closed due to the fact that the question is too common for the participants in pavel , Kromster , cheops , rjhdby , fori1ton 24 Oct '16 at 7:57 .

Please correct the question so that it describes the specific problem with sufficient detail to determine the appropriate answer. Do not ask a few questions at once. See “How to ask a good question?” For clarification. If the question can be reformulated according to the rules set out in the certificate , edit it .

    1 answer 1

    Write a record with a specific IP to the database and specify the access текущее время + 10800 . And in the desired file, check whether access to a given IP is open (and whether the time specified in the column is longer than the current one, if yes, then open access).

    • I am new to this business, it is possible in more detail, which database and is it possible to do this automatically for all IPs? - Sergey Sidorenko
    • Do you want to implement this on the site? - ikerya
    • I have a website, I need every visitor to see the contents of a particular page no more than once every 3 hours. - Sergey Sidorenko
    • This page: taxi-picnic.ru/… - Sergey Sidorenko
    • one
      When a user visits a particular article, add a record with this IP, and the number of seconds (in php the time function) + 10800 (3 hours. Ie the user will be able to see the page again after 3 hours). Then, if the user visits the page again, check if there is a record with a restriction and a column that contains time (seconds), and if this time matters more than the current time, then restrict access. This task is implemented using PHP and MySQL - ikerya