Run Code  | API  | Code Wall  | Users  | Misc  | Feedback  | Login  | Theme  | Privacy  | Patreon 

website url validation using php


            
                
            
 run  | edit  | history  | help 0

<?php //php 7.0.8 $website = 'www.123.com'; $a= preg_match("/\b(?:(?:https?|ftp):\/\/|www.)[-a-z0-9+&@#\/%?=~_|!:,.;]*[-a-z0-9+&@#\/%=~_|]/i",$website); echo $a; ?>

  by  mseenug@123, 1 years ago


Very nice, I used this before redirecting to make sure the URL was valid. If interested here is the guide on how to redirect PHP.

  by  programmerdude2341@gmail.com, 8 months ago




Please log in to post a comment.
AAA