• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how do i validate a url?


i wanted to validate a url. Using PHP REGEX.

i have got some REGEXs by googling but all of them have flaws in them.

I wanted to match

all of these:
google.com/anything (or ?query )

but not javascript-: or mailto: can anyone help?

hey i am trying to type js protocol but expression-engine (the cms used here) removes it Big Grin

no reply Sad

@shaheer... so, it looks like you waited 31 minutes to bump the thread - on a saturday. next time you might be more patient, especially with a problem that isn't directly CI related.

this page of this thread might help you parse URLs. let us know how it works out as this code should be in the auto_link function which would obviate your problem.


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.