We usually don't often think of checking the validity of a URL address, or don't care about its existence or non-existence: Because there is basically no such application on weekdays. Today, let's see how to use PHP to check whether a URL exists.
How do I check whether a string exists in the page URL? In view of security, if you want to obtain the url of this page, check whether the string "script" exists. If yes, access or exit is prohibited. How to implement it? ------ Solution ------------
How do I check whether a string exists in the page URL? In view of security, if you want to obtain the url of this page, check whether the string "script" exists. If yes, access or exit is prohibited. How to implement it ?, Strstrstrpos,
This article gives you the content is about how to check the existence of the remote file in PHP (pure code), there is a certain reference value, the need for a friend can refer to, I hope you have some help.
Check if the remote file exists
PHP to determine whether a Web page exists, the simple way is fopen/file_get_contents. Wait, there are a bunch of ways to do it, but these ways will be the whole page of HTML pull back, to judge a lot of web site data, it will be a bit slow.
To be
such as pagination, because some links already have parameters, in addition to the paging information can not discard the original parameters, so to determine whether the link has parameters, and then additional paging information as needed.
The
The phpwindow platform simulates the checkdnsrr function to check whether the email actually exists. There is a checkdnsrr function in the php system function. This function is used to check whether a DNS record exists based on a given hostname or
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.