- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
What is import attribute in JSP?
The import attribute serves the same function as and behaves like, the Java import statement. The value for the import option is the name of the package you want to import.
To import java.sql.*, use the following page directive −
<%@ page import = "java.sql.*" %>
To import multiple packages, you can specify them separated by comma as follows −
<%@ page import = "java.sql.*,java.util.*" %>
By default, a container automatically imports java.lang.*, javax.servlet.*, javax.servlet.jsp.*, and javax.servlet.http.*.
Advertisements
To Continue Learning Please Login
Login with Google