small javascript code to check urls..

(To be done either in javascript or using jQuery)

- A form has a textfield: search_or_url e.g.

<form method="post" action="#" id="myForm">

<input type="text" name="search_or_url" /><br />

<button name="Search or Add" type="submit"></button>


- On Submission of form. Strip whitespace at ends of search_or_url Check:

Is search_or_url a URL?

If it is, Does the URL fit one of these:

[url removed, login to view][string]

[url removed, login to view]:[int]

[url removed, login to view][string]

[url removed, login to view][string]

[url removed, login to view][user]/[string]

(NB: should cope with [url removed, login to view] or [url removed, login to view])

If it does alert('/save/domain/[url]/[parts]')

e.g. /save/sourceforge/projects/sawat





If it doesn't match these alert('cant add site yet')

If it isnt a url, alert('searching for '[entered text]').

Habilidades: Javascript, jQuery / Prototype

Ver más: code javascript auto popup lightbox, google check code, code converte char int, html javascript small projects, vote code javascript, dynamic urls voucher code, check code injection php, update code javascript, check check code process design, pizza order form code javascript, check code website crawler, crm ult conversion timezone code javascript, javascript small chat, check scroll javascript, check mouse javascript, google spell check service javascript

Información del empleador:
( 26 comentarios ) Faversham, United Kingdom

Nº del proyecto: #12151913

Adjudicado a:

£11 GBP en 1 día
(2 comentarios)

2 freelancers están ofertando el promedio de £15 para este trabajo


Hi, Firstly, Thank you for reviewing my proposal. I have gone through your requirements and came to know that you need an expert web developer to build your website. I have strong knowledge and 3+ years experience i Más

£18 GBP en 1 día
(0 comentarios)