處理struts2自帶的錯誤提示

struts2-core.jar包中的

 struts-messages.properties文件中有定義:

struts.messages.invalid.token=The form has already been processed or no token was supplied, please try again.

你可以在自己的項目根目錄裏建立一個message_zh_CN.properties文件

 文件內容是:

 struts.messages.invalid.token=需要顯示的中文的Unicode 可以用java的native,獲得中文的unicode 獲取unicode的方法:

 用cmd,在jdk的bin目錄裏:native2ascii回車 然後輸入需要的中文再回車

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章