1.1 Java Servlet and Its FeaturesServlet is the answer of Java technology to CGI programming. Servlet programs run on the server to dynamically generate Web pages. Compared with traditional CGI and many other CGI-like technologies, Java Servlet is
The following three statements are used on the jsp (preferred for SUN Enterprise Applications) page to ensure gbk encoding.
Use the following statement to connect to a database:String sConnStr = "jdbc: MySQL (the best combination with PHP): //
3. Interaction with XML through tag library JSPThis is what I mentioned earlier, but because it is too important, I must also mention it in this article. The tag library can define the custom tags that appear on the JSP page as XML-like elements,
Assumerver Pages (JSP) and XML are two crucial components of Sun's J2EE. JSP is an effective tool for creating application server programs, and the customer can be a browser, a device, or other applications. You can use XML to describe the data and
Open the file 1.htmin the main window, and pop up the window page.html at the same time]Add the following code to the area of the main window: 〉Join the area: open .[6. timed close control for the pop-up window]Next we will make some control over
[9. Ultimate application-Cookie control in the pop-up window]In retrospect, although the pop-up window above is cool, there is a small problem (immersed in joy, there is no discovery ?) For example, if you place the above script in a page that
The Custom Tag (Custom tags) implements javax. servlet. jsp. tagext. Tag or javax. servlet. jsp. tagext. BodyTag.Interface. Use javax. servlet. jsp. JspWriter to output.The TagSupport class provides implicit implementation of the interface Tag.
I. PrefaceThe 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 follows:
(Editor: when the original article appeared abroad for the first time, JSP was just a new technology and was not as popular as it is now. It seems that some of the ideas in this article may have some limitations, but I have to admit that this is a
At the beginning, jsp (the preferred choice for SUN enterprise-level applications) was used for web applications, like PHP and ASP (the preferred choice for SUN enterprise-level applications ), there is a lot of scriptlet in the HTML code-that is,
Note: The following urls do not contain ContextPath.
Servlet ing URL specification
1. Indicates path ing starting with/and ending with/*, that is,/Test/* indicates that the request path starts with/Test/is mapped to the Servlet for processing.2.
A new programming approach (below): GBDP, a "demand-oriented" Programming MethodRare confused Programming Method GBDP (applicable to jsp (preferred for SUN Enterprise applications), asp and other programming)In "on" and "on", I have released the
The deployment descriptor is an XML file. For details, see the relevant documentation. This only describesDeploy TagLib.JSP custom tag libraries (optional)Specifies URL for locating Tag Library Descriptor...UriPath.../*************** Example of
Creating an HTTP Servlet usually involves the following four steps:
1. Extend the HTTP servlet abstract class.
2. Reload the appropriate method.] For example, override (or rewrite) The doGet () or doPost () method.
3. Obtain the HTTP request
I. InstallationJsp (preferred for SUN Enterprise Applications) SmartUpload is developed by www. jsp (preferred for SUN Enterprise Applications) a free-of-charge full-featured file upload/download component developed on the smart.com website,
Database-related operations: such as connection, query, addition, deletion, modification, and paging display Package study. database;
/*** Title: jsp (preferred for SUN Enterprise Applications) model learning * Description: database related
A learning process for beginners of jsp (preferred for SUN Enterprise Applications) (7)TheUnforgivenChapter 7 Operations on ultra-long text-Access to Clob dataWhen I wrote a message board, I wanted to store the body content of the message board. I
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