Validating dropdownlist javascript

aspdotnet-suresh offers C#articles and tutorials,csharp dot net,articles and tutorials, VB.How to validate that string contains only alphanumeric value with some spacial character and with whitespace and how to validate that user can only input alphanumeric with given special character or space in a textbox (like name fields or remarks fields).

validating dropdownlist javascript-27

CActive Form provides a set of methods that can help to simplify the creation of complex and interactive HTML forms that are associated with data models.

The 'begin Widget' and 'end Widget' call of CActive Form widget will render the open and close form tags.

Most other methods of CActive Form are wrappers of the corresponding 'active' methods in CHtml.

Calling them in between the 'begin Widget' and 'end Widget' calls will render text labels, input fields, etc.

For example, calling CActive Form::text Field would generate an input field for a specified model attribute.

What makes CActive Form extremely useful is its support for data validation.

CActive Form supports data validation at three levels: All these validations share the same set of validation rules declared in the associated model class.

CActive Form is designed in such a way that all these validations will lead to the same user interface changes and error message content.

To ensure data validity, server-side validation is always performed.

By setting enable Ajax Validation to true, one can enable AJAX-based validation; and by setting enable Client Validation to true, one can enable client-side validation.

Note that in order to make the latter two validations work, the user's browser must has its Java Script enabled.

Tags: , ,