If you need stronger security, consider using HTTPS protocol. Note that with this authentication method your browser will pass your username and password Our CheckAccess()įunction could be implemented like this: The Basic HTTP authentication forces visitor's browser to show prompt askingįor username and password in order to access restricted area. Restrict Access Using Basic HTTP Authentication Without this parameter you can return 404 HTTP (Page Not Found) response code as described below. You can get access to your scriptīy supplying arbitrary additonal parameter within the script URL, e.g. PHP script and do not want to write much code. This very simple technique can be used if you want to restrict access to the Your verification function could be as follows: = ip2long($fromip) & $ip Add an Additional Hidden Parameter IP addresses (for example, IP range of your organisation, school, etc.), If you want to allow access to your PHP page only for the range of static If you have a static IP address, you can hardcode it in your verification function somehow like this:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |