Day 3-student information management for JSP & servlet!

Source: Internet
Author: User

By the way to help the master to promote the original http://www.java1234.com/a/yuanchuang/ video tutorial, although not professional training structure, but fortunately explain delicate, easy to understand!

I have always thought that JSP & servlet is too simple and troublesome, so I only understand the operation, but I have never actually done anything. Later I went on to study the framework inexplicably. After my master's tutorial, I feel very benefited a lot ~ I feel totally different at once! Bunker ~~

I will copy some of the messy notes below, but I can understand it myself. Well, especially the paging submission of easyui, this is definitely a classic case.

Easyui paging submission
Current page

Number of records per page in rows

Select * from data table name limit start, size;
Start: from where it is displayed, page-1) * Rows can be obtained.
Size: number of records per page

Select count (*) as total from t_grade gets the alias for storing the number of records to total

Batch Delete

Delete from tablename (Table Name) where field in (1, 3, 6 );
// Field indicates the field name
// Delete the entry with field value 1 3 6

Firfox also supports breakpoint, type debug

Join method of the array: Convert the string into an array, which is automatically matched.

Jquery POST method

Four parameters: First: Submission path
Second: Submit Parameters
Third: callback Method
Fourth: Submitted data type

$. Post ("gradedelete", {delids: IDS}, function (result ){
If (result. Success ){
Alert ("deleted successfully! ");
} Else {
Alert ("deletion failed! ")
}
}, "JSON ");

Garbled information during asynchronous submission may be generated after submission
Request. setcharacterencoding ("UTF-8 ");

$ ("# S_sex"). ComboBox ('getvalue ')

Time query in MySQL, convert to days, and then query
"And to_days (S. Birthday)> = to_days ('" + beginbirthday + "')"

// Clear easyui
$ ("# Sex"). ComboBox ("setvalue ","");

Hidden uses the hidden field to hide the submitted Form

Remember to pay attention to the cascading deletion issue when associating tables.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.