Difference 1:URL changes in the browser during redirectionThe URL on the browser remains unchanged for forwarding.Difference 2:Redirection actually generates two requests.Only one request is forwarded.Redirection:Send a request --> run the server -->
1, form get method to submit parameters garbled, because the default tomcat according to the iso-8859-1 for url encoding so the corresponding conversion:@ First, set the request Encoding Method on the acceptance parameter page or servlet, for
JSP nine implicit objects
Request
Response
Config
Application
Exception
Session
Page
Out
PageContext
Out implicit object
The out implicit object is used to send text data to the client.
The out object is returned by calling the getOut method of
1. Use of simple labels
1) use custom tags to control whether the page content (TAG body) is output
Public void doTag () throws JspException, IOException {
// JspFragment jf = this. getJspBody ();
// Jf. invoke (null );
// Equivalent to jf.
when the types in the tag are password and text, their default length and width are inconsistent, and the length and width of the types in the logon box are usually set to be consistent. The following methods can be used to make them consistent
JSP script ElementJsp declaration Syntax: The jsp declaration is only valid on the current page, and the jsp built-in object cannot be used in the jsp declaration. The variables or methods declared in it are instance methods or instance
The key to Chinese display is to identify at which stage the problem arises;
When obtaining data submitted by a jsp form:
Filter can be configured in web. xml (before struts filter must be configured)
encodingFilter org. springframework. web.
In the network, changing the encoding from gb2312 to gbk does not take effect for a long time, including servelt, because it is garbled by default with the servlet itself in the database.
Later, we changed the page encoding to gbk on the jsp page,
Recently, I used kindeditor4.1 to edit an article and found that an error occurred while uploading the flash file and media file. I cannot solve this problem. I found out that the struts framework encapsulates the request object by looking for a
Type 1: struts1.2 looping element. name indicates the result set. Reference tag library [Java]$ {x. u_id} $ {x. u_name} $ {x. u_sex} modify Delete
Type 2: struts2.0 looping element. Note: value is the result set. Reference the tag library
Introduce CKEditor to the page:1. 2. Add class = "ckeditor" to the "content" textarea tag"
After the introduction, you can use CKEditor to edit the content of the text box, for example:
, TextArea has become a visual editing areaAfter editing the
1. a Jsp page is a common text file consisting of HTML statements and embedded JAVa code. The JSP page file extension is. jsp.
2. Both jsp and Servlet can develop dynamic web resources, but the two are different. servlet is used as the Controller
Servlet Filter)Introduction to FilterFilter is also called a Filter. It is the most exciting technology in Servlet technology. WEB developers use the Filter technology to manage all web resources on web servers, such as Jsp, Servlet, static image
A moment of cheap, the structs-config.xml file in a paragraph deleted, the results are always reported error.Error message: Document is invalid: no grammar found[Html] "-// Apache Software Foundation // DTD Tiles Configuration 1.3 //
Function: automatically uploads the 02view.html file under the same directory in 5 seconds. 1) html implementationAdvantage: simpleDisadvantage: cannot be used in Struts Tiles 2) javascript implementationAdvantage: flexible, can be combined with
Summary of the process of passing JSP page parameters!Transfer Process:
1. if you click to connect to the Jsp page, the transfer process is xxx. action request --> action --> Jsp. You must use action before entering the jsp page. Therefore, the
When using the EL expression in JSP, You need to identify isELIgnored = "false". Otherwise, the EL expression is compiled as a normal string and the correct value is not displayed on the page. [Html] you can see this in the
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