Validate the data for enterprise web applications.

UPDATED: 15 April 2012
 If you are web developer then you must validate some data. I did validation part easy for you guys. Check out the validate class in latest javaQuery API. Let me tell you what i included in new validation class.






  • Get file extension of any file
  • Validate the email
  • Remove html tags.
Check the below example that show the demo of the API:

import javaQuery.validation.validate;

public class RunCode {
    public static void main(String[] args) {
        validate _validateData = new validate();
        String strfile_Extension = "test.mp3";
        String strhtml_Data = "This test is bold";

        System.out.println("File extension: " + _validateData.getFileExtension(strfile_Extension));
        System.out.println("Email is: " + _validateData.Email("vkijust4u@javaquery.com"));
        System.out.println("HTML tag normalized: " + _validateData.removeHTML(strhtml_Data));
    }
}
Output : 
File extension: .mp3
Email is: true
HTML tag normalized: <b>This test is bold</b>
So now you don't need to write bunch of codes to validate the email address/ remove html tags and get the file extension of any file.

2 comments :