18.221.154.151 |    

Navigation

Google Advertisement

Diese Funktion prüft das Adressformat einer Url. Diese Funktion gibt True oder False zurück.

check_url
  1. def check_url( url ):
  2.     """check_url --- Check the syntax of a url format and return False
  3.     if the syntax is bad and True if the syntax is good.
  4.  
  5.     (bool) bool check_url( (string) url )"""
  6.     from re import compile, match
  7.     regexp = compile( '^(f|ht)tps?://.+\..+/?' )
  8.     if regexp.match( url ) != None:
  9.         return True
  10.     else:
  11.         return False
Parsed in 0.002 seconds at 242.41 KB/s

Search
 
Full text search by name and content of a snippet.

User online
There are 1 users online.

Tags Cloud

Latest snippets
str2seconds
(Bash::Function)
is_integer
(Bash::Function)
file_rotate
(Bash::Function)
confirm
(Bash::Function)
is_workingtime
(Bash::Function)
last day of last month
(Bash::Snippets)
crypt_apr1_md5
(PHP::Function)
crypt_apr1_md5
(Perl::Function)
transparent
(CSS)
rfc2822Toiso8601
(PHP::Function)