主页 > 编程资料 > JSP(JAVA) >
发布时间:2016-01-01 作者:网络 阅读:331次
jsp或servlet页面代码:
复制代码 代码如下:
String driver = application. getIni tParameter ("driver") ;
String url = application.getInitParameter("url");
String user = application.getInitParameter("user");
String pass = application.getInitParameter("pass");

web.xml需要读取的内容:
复制代码 代码如下:

driver
com.mysql.jdbc.Driver


url
jdbc:mysql://localhost:3306/j2ee


user
root


pass
32l47

关键字词: