Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CFFORM Validation 1

Status
Not open for further replies.

jmcg

Technical User
Jun 30, 2000
223
GB
Anyone offer any help on this. I have a CFFORM with a couple of CFINPUT validation that works fine on my localhost test but when I upload it does not work. It simply sends the form without any of the validation
I have other form using similar setups that do work but cannot put my finger on why this would not work!
Code:
	<cfform action="contact.cfm?send=1">		
	Name:<br>
	<cfinput name="Name" type="text" size="30" required="yes"><br />
	Email:<br>
	<cfinput type="text" name="email" size="30" required="yes" validate="regular_expression" pattern="^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$" message="Please check the email address is complete and in the correct format"><br>
	Comments:<br>
	<textarea name="Comments" rows="5" cols="5"></textarea>
	<br />	
	<input type="submit" value="Contact Us">		
	</p>		
	</cfform>
 
It fails in both FF and IE online.
Works in both on the localhost
 
Look at the source code created by the cfform tag and see if you can access the .js files. cfide may not be mapped correctly.

you should also get JS errors in the browser. Might be too fast to catch in IE but you should be able to see them in the firefox error console. Tools > error console.
 
Was an erroneous line in the CSS sheet.
excellent pointer though,thanks very much.
 
Just as a "good to know fact" what kind of a CSS error would cause the <cfform> validation to fail? Was it the usage of the #-sign ID Selector that caused this?

_____________________________
Just Imagine.
 
It was actually just a bit of code that was in the CSS that should been in html, a random paste by me.
It was not related to the form at all:
Code:
td{
	padding-top: 15px;
	line-height: 10px;
	font-size: 0.8em;
} bgcolor="#808080">
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top