var pattern =
/^https?:\/\/[-a-z0-9]+(\.[-a-z0-9]+)*\.([a-z]{2,3}|aero|coop|info|museu
m|name)\/?$/i;
return pattern.test(url);
}
Watch out for wrapping of the regexp!
Pascal
> -----Original Message-----
> From: Tangorre, Michael [mailto:[EMAIL PROTECTED]
> Sent: woensdag 3 maart 2004 12:46
> To: CF-Talk
> Subject: OT: _javascript_ to Check link format...
>
> Does anyone have a JS function to check the format of a link
> submitted by a user via a form.
>
> I would like to make sure the format is:
>
>
>
> http://www.somesite.someExtension
> <http://www.somesite.someextension/>
>
>
>
> Thanks!
>
>
>
> Mike
>
>
>
>
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

