/    Sign up×
Community /Pin to ProfileBookmark

Validation (Date) script from "Javascript Source"

I have been using this Vaildation (Date) javascript from “Javascript Source” for some time now but have recently encountered a problem.

I have an application where I need to use a text link rather than a button to initiate the date check and had expected to be able to use:

<a href=”javascript:doDateCheck(this.form.from, this.form.to);” title=”Check Dates”>Check Dates</a>

in my form, instead of the usual button shown in the sample html page:

<input type=”button” name=”checkbutton” onClick=”doDateCheck(this.form.from, this.form.to);” value=”Check Dates”>

Although the alternative text link works fine in Internet Explorer and Opera browsers, it will not work with Firefox or Netscape browsers.

I wonder if any of you have any suggestions?

BTW: The contact e-mail for Mike Welagen ([email protected]) bounces back.

to post a comment
JavaScript

3 Comments(s)

Copy linkTweet thisAlerts:
@phpnoviceJun 08.2006 — The [b]this.form[/b] reference is invalid from a link because a link is not a form element. You'll have to change that to a full form object reference.
Copy linkTweet thisAlerts:
@nzguyauthorJun 09.2006 — Thanks phpnovice. How stupid! I kept looking at it and couldn't see what was staring me in the face.
Copy linkTweet thisAlerts:
@phpnoviceJun 09.2006 — No problem.

Cheers.
×

Success!

Help @nzguy 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 5.18,
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: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

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

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...