Support Forum Softcomplex logo
About Us  | Services  | Download  | Order  | Support  | |
| Search | Today's Posts | Stats | Board Rules | Not logged in [ Login | Register ]
go to bottom
Last active: Never

Printable Version | Subscribe | Add to Favourites   Post new thread
Author: Subject: How do I control the CSS class of labels BEFORE a form is validated?
pengman
Junior Member

Posts: 4
Registered: 10/15/2008
Location: UK
Member Is Offline
posted on 10/15/2008 at 03:41 PM Reply With Quote
How do I control the CSS class of labels BEFORE a form is validated?


I can control the text style I want after the submit button is clicked (in this case, blue for a correctly completed field, red for in incorrectly completed or empty field), but I can't control them before the sumbit button is clicked (i.e. I only have my machine default style).

My CSS classes for validator are as follows:-

/* classes for validator */
.tfvHighlight {
font-family: Arial, Helvetica, Geneva, Sans-Serif;
font-size: 10pt;
font-weight: bold;
color: red;
}
.tfvNormal {
font-family: Arial, Helvetica, Geneva, Sans-Serif;
font-size: 10pt;
font-weight: bold;
color: navy;
}

My code for a typical form field is as follows:-

<td id="t_first_name" align="right" width="25%">First Name:
</td>
<td align="left" width="25%">
<input type="text" size="25" name="first_name">
</td>

The above code is similar to your Demo1, so I'm mystified as to where Demo1 is getting its pre-submit control of labels from.
View User's Profile View All Posts By User U2U Member
pengman
Junior Member

Posts: 4
Registered: 10/15/2008
Location: UK
Member Is Offline
posted on 10/17/2008 at 04:43 PM Reply With Quote

Sorted this myself. What i didn't have was a style for 'td'. Once I added that, all was well.
View User's Profile View All Posts By User U2U Member
Post new thread

Related Links:
Product Page Product Page
Product Demonstrations Product Demos
Registration Form Validation
Login Form Validation
Free Download Free Download
Product Documentation Documentation
Documenation Page
Change Log
Validators Comparison Table
Support Forum Support Forum
 

Go To Top


Powered by XMB 1.9.1 Nexus
Developed By Aventure Media & The XMB Group © 2002-2004