java ssi_快速部署SSI框架
1.先準(zhǔn)備搭建框架要使用到的架包,放到項(xiàng)目的lib文件夾中如下圖:
2.開始配置web.xml
服務(wù)器啟動(dòng)時(shí)首先加載這個(gè)文件,
Spring使用ContextLoaderListener加載ApplicationContext配置信息,web應(yīng)用啟動(dòng)的時(shí)候來初始化WebApplicationContext
Struts2配置
配置啟動(dòng)頁面
按照上面三個(gè)步驟整個(gè)web.xml基本配置已經(jīng)完成
3.配置struts.xml文件
4.配置Spting.xml文件
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd"
default-autowire="byName" default-lazy-init="true">
5.配置Mybatis.xml
6.配置WxclDAO.xml
SELECT
USER_ID AS userId,
USER_NAME ?AS userName
FROM USER_TABLE
WHERE
USER_ID=#{userName}
整個(gè)SSI框架算是基本搭建完成了
總結(jié)
以上是生活随笔為你收集整理的java ssi_快速部署SSI框架的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: G1回收器介绍
- 下一篇: html5游戏源码素材哪家强?Top3都