「Struts2 でリンクボタンを作るには」の版間の差分
提供: tknotebook
(ページの作成:「Category:コンピュータCategory:JavaCategory:Struts2 メインページ>コンピュータの部屋#Java>Struts2 Tips struts2 でリ...」) |
(相違点なし)
|
2016年12月16日 (金) 14:09時点における最新版
メインページ>コンピュータの部屋#Java>Struts2 Tips
struts2 でリンクボタンを作るには以下のようにします。
例えば 名前空間=/UserList アクション=show に遷移するボタンを作るには
<s:url var="userlist_show_url" namespace="/UserList" action="show" /> <button type="button" onclick="location.href='${userlist_url}'">ボタンのキャプション</button>