Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Daedleh
Aug 25, 2008

What shall we do with a catnipped kitty?

golgo13sf posted:

sorry, I misunderstood:

Combine it with the other code to do a full verification (email addresses match and are in a valid format)

I actually came here to ask about this very problem as I'm having some trouble with differences between IE & Firefox. This is the code I've got:

code:
	//Check if the user has entered an email address
	var email = document.getElementById('email').value;
	if (email.length == 0 ) {
		alert('Please enter an e-mail address.');
		document.getElementById('email').focus();
		return;
	}

	//And if they've confirmed it
	var cemail = document.getElementById('con-email').value;
	if (cemail.length == 0 ) {
		alert('Please confirm the e-mail address.');
		document.getElementById('con-email').focus();
		return;
	}

	//And check that the email and confirmation match.
	if (cemail != email) {
		alert('The e-mail addresses provided do not match.');
		document.getElementById('con-email').focus();
		return;
	}
Now I can't see any differences in the relevant code between my final check and what you've put but while the code works fine in Firefox, in IE8 (windows 7 so I don't have the others to hand) it always gets a mismatch.

The page I'm trying to get it working on is here (yeah go ahead and mess about if you want. It will send out an e-mail with a random password but there's nowhere to login yet):
http://nickjwilliams.co.uk/cms/l-administrators.php

Adbot
ADBOT LOVES YOU

Daedleh
Aug 25, 2008

What shall we do with a catnipped kitty?

golgo13sf posted:

Found it, change the "name" property of your username input tag, right now it's:

code:
<input id="username" name="email" type="textbox" class="inputtext">
IE doesn't like it sharing the name with the email input tag.

:doh: Thank you

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply