ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old May 12th, 2004, 12:46 PM
sunbigsmile sunbigsmile is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 27 sunbigsmile User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question required and message attribute

I included required and message validate attributes. However, it doesn't show any message when I tried to put some error and not put data.
<cfinput type="text" name="userPassword" maxlength="6" required="yes" validate="integer" message="you must enter password and only 6 numbers are allowed">

Does anyone know why?
Thank

Reply With Quote
  #2  
Old May 12th, 2004, 02:36 PM
kiteless kiteless is offline
Moderator
Dev Shed Expert (3500 - 3999 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 3,682 kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 15 h 25 m 55 sec
Reputation Power: 53
Hmm...not sure what you are doing wrong. When I run this code, it works:

<cfform action="temp2.cfm" method="POST">
<cfinput type="Text" name="userPassword" message="you must enter password and only 6 numbers are allowed" validate="integer" required="Yes" maxlength="6">
<input type="submit" name="submit" value="Submit">
</cfform>

Reply With Quote
  #3  
Old May 14th, 2004, 09:48 AM
sunbigsmile sunbigsmile is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 27 sunbigsmile User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question It did not work neither - required and validate attribute

I don't know why it did not work. I tried to put text in the field instead of integer as I put in validate attribute. However, it did not open a little window with the error message. It only showed me a grey page of error message like the one you will see when you worked with coldfusion.
In addition, I left the field blank. It did not showed a window with error message but the grey page of error message as the above. Do you know why?

Reply With Quote
  #4  
Old May 14th, 2004, 09:52 AM
bfolger71 bfolger71 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Location: Boston, MA
Posts: 47 bfolger71 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 34 sec
Reputation Power: 6
This might seem like a stupid question, but are you using <cfform> rather than <form>?

Reply With Quote
  #5  
Old May 18th, 2004, 09:22 AM
sunbigsmile sunbigsmile is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 27 sunbigsmile User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question required, validate and message attribute not working

Yes, that is why I don't know why it doesn't works. I used cfform. DO you have any suggestion. Can I use pop up message? if I can, how can I tell it to validate what user has entered

Last edited by sunbigsmile : May 18th, 2004 at 01:03 PM.

Reply With Quote
  #6  
Old July 23rd, 2004, 08:20 PM
cozmotrouble cozmotrouble is offline
Duck herder
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2002
Location: My crib
Posts: 5 cozmotrouble User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 49 m 58 sec
Reputation Power: 0
Send a message via AIM to cozmotrouble
Quote:
Originally Posted by sunbigsmile
I included required and message validate attributes. However, it doesn't show any message when I tried to put some error and not put data.
<cfinput type="text" name="userPassword" maxlength="6" required="yes" validate="integer" message="you must enter password and only 6 numbers are allowed">

Does anyone know why?
Thank


I got it

Create the directories /CFIDE/scripts/ under the root of your site. Copy the cfform.js script file from the directory of your ColdFusion server to the /CFIDE/scripts/ Dir of your site.


Or

In cfform Specify the path to cfform.js using the scriptSrc attibute.

Example <cfform Action="Whatever.cfm" scriptSrc="/CFIDE/scripts/cfform.js">


Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > required and message attribute


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway
Stay green...Green IT