/    Sign up×
Community /Pin to ProfileBookmark

Confirm and alert

I was wondering if I can do this with Javascript:

I have a form and want to validate the name and email. If everything is good I need a confirm dialog box in the dialog box I want a choice to submit a php page or to cancel. If the validate fails I need it to go back to the form and put focus on the input field that was wrong. If anyone can let me know what I need to do or how I would go about doing this I would greatly appreciate it.

Thank you in advance.

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@grumpyOleManMar 19.2013 — form validation is the bread and butter of web development and there are literally millions of web pages with people trying to help you understand how it is done.

if you do a search for *form validation with JavaScript* you will be overwhelmed with results..

work through one or two and you will get an idea on how to do it.

as for the dialog box that will answer itself when you get a handle on form validation...
×

Success!

Help @Vince_M spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...