“PHP Verifique se a string contém URL” Respostas de código

PHP se o URL contiver

if(strpos($_SERVER['REQUEST_URI'], "string")) {
  ...
}
RedBredren

Verifique se uma string é URL ou não PHP

<?php
  if(filter_var($imagePath, FILTER_VALIDATE_URL) === FALSE){
      echo "Not valide URL";
  }else{
      echo "valide URL";
  }
Beautiful Bug

PHP Verifique se a string contém URL

preg_match('/(http|ftp|mailto)/', $string, $matches);
var_dump($matches);
Tiago F2

Respostas semelhantes a “PHP Verifique se a string contém URL”

Perguntas semelhantes a “PHP Verifique se a string contém URL”

Mais respostas relacionadas para “PHP Verifique se a string contém URL” em PHP

Procure respostas de código populares por idioma

Procurar outros idiomas de código