The principle is as follows:
1. Write a class to generate a picture file (Image.java)
2. Write a JSP file to generate the picture (createimage.jsp)
3. Write a homepage to display the Picture Verification Code (IMAGE.JSP)
4. Write a JSP file,
I. Introduction of Labels
In fact, we have used a few tags in the JSP, such as , , these tags are predefined, if we need to customize the label, we need to learn the label programming.
The advantage of label programming is flexibility +
introduction of Built-in objects
Built-in objects cannot be in .
Built-in objects
Owning class
PageContext
Javax.servlet.jsp.PageContext
Request
Javax.servlet.http.HttpServletRequest
1, post submission data is implicit, get is passed through the URL (you can look at the address bar of your browser), used to pass some data that do not need to be classified.
2. When using get, the size of the transmitted data is limited (note
Solution:
Step 1. Add a filter, that is, in the filter in init () plus request.setcharacterencoding ("Utf-8"), the equivalent of each page encoding is utf-8,
Step 2. Change the form submission method to post mode, as far as the get way is
transfer request information from a JSP file to another JSP file, and the rest of will not be executed.You can use to pass parameters.
place the included files in JSP and execute them with others.
In JSP, there are two ways to jump to a page:
JSP enterprise interview questions (4)5-1. Briefly describe the relationship between Servlet and JSP.
JSP is implemented in another way. servlet is an earlier version of JSP. In JSP, it focuses more on the page performance, while in servlet, it
During the interview today, the technical officer asked this question. I sorted it out:
Forward () Acts on the server,After redirection, the URL address of the browser remains unchanged, so the parameters cannot be passed through the get
Many beginners are always confused about the relationships and differences between JavaScript, Java, JSP, and J2EE. To help you quickly understand the relationships between several users, we have explained the following:
1. Javascript is used to
This is a simple comment system, using the JDOM (here using Jdom-b9), the instance uses JSP as the view, combined with Ajax (using prototype-1.4), Servlet and JavaBean as the background processing, use an XML file to store data.
1. The application
I. Preface
The original author of this article is Tony Wang. This article involves file read/write and automatic jpg image generation. Using JSP + Servlet technology, JSP calls servlet to generate images.
Ii. index. jsp of the first file is as
Today, it is really annoying to refactor a project... Look at the big head, alas .... There was a problem. There was no problem with the local test. An exception occurred when publishing to the remote server, which was very strange.
The
1. Javascript parameter passing: this parameter passing method uses the opener keyword to implement cross-page parameter passing. Its usage is to use the opener keyword to call a component of the parent form.
Example: opener.myform.txt. value =
JSP is a dynamic web page technical standard proposed by Sun and established by many companies. With JSP technology, web page developers can use HTML or XML tags to design and format the final page. Use JSP tags or scriptlet to generate dynamic
Objective: l further understand JSP applications; l understand the use of expression languages; l master the use of standard tag libraries; l master the use of labels; l master label usage; l master the use of the log on to User ID: password:
After a long time, I forgot the basics. Let's take a look at it today. Hehah... learn new things with a warm understanding !!!
1. requestdispatcher. Forward ()-forwardIs used on the server. When forward () is used, the servlet engine transmits
Author: fbysssDisclaimer: This article is original in fbysss. If you need to reference it, please indicate the author and reference addressKeywords: smartupload, uploadbean, Linux, Chinese garbled charactersI. smartupload file garbled solution
I. Script element: insert Java code into the servlet corresponding to the JSP page. The form of script element 3:Expression, scriptlet, declaration.2. expression: Convert the data or data operation result to a string and insert it to the input
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