Is there any regx to detect complete url
In my code i am using this regx urlRegex to find out any url in my content editable iframe's text
urlRegex = /http(s?):\/\/($|[^ ]+)/
iam getting issue when i type http:// this gets detecting and this is not detecting www.google.com
i have to detect url's like
http://www.google.com
https://www.google.com
www.google.com
http://localhost:51932/default.aspx
my code is
var iframe = Iframe,
textbox = iframe.contents().find("body")[0],
urlRegex = /http(s?):\/\/($|[^ ]+)/;
In this question Autolink URL in ContentEditable Iframe i am trying to fix regx
Please help
Thanks