i am writing a regular expression to check a website URL it should check the following scenarios:
pass:
- www.example.com
- example.com
- www.example.com/something
- example.com/something
and prevent every other urls
its working perfectly for every thing except one case (www.example), how can i handel this case
"www.example" must not pass
my regular expression :
^[a-zA-Z0-9][a-zA-Z0-9]+([.][a-zA-Z0-9]+)+(/.*)?$
can any one help please ?
Thanx.