Answers for "php check url has string"

PHP
5

check if valid url php

filter_var($url, FILTER_VALIDATE_URL);
Posted by: Guest on April-16-2021
1

php check if string contains url

preg_match('/(http|ftp|mailto)/', $string, $matches);
var_dump($matches);
Posted by: Guest on August-28-2020

Browse Popular Code Answers by Language