摘要: 在webapps中新建文件夹H,在其中再创建WEB-INF文件夹,在创建classes文件夹和web.xml文件,web.xml需要配置一下,classes文件夹中存放Servlet经编译过的class文件;在localhost中创建H.xml配置一下路径等。 阅读全文
posted @ 2014-06-05 21:09 功夫小子1917 阅读(287) 评论(0) 推荐(0) 编辑
摘要: web.xml中url-pattern的值必须和相关联的jsp页面form中的action的值一样,才会从jsp页面跳转到servlet。 阅读全文
posted @ 2014-06-05 21:07 功夫小子1917 阅读(410) 评论(0) 推荐(0) 编辑
摘要: try { Class.forName( "org.postgresql.Driver" ).newInstance(); String url = "jdbc:postgresql://localhost:5432/postgres" ; ... 阅读全文
posted @ 2014-06-05 21:06 功夫小子1917 阅读(342) 评论(0) 推荐(0) 编辑