struts1 bean message key


资源文件中字符串带有单引号“'”时jsp页面显示异常事例

资源文件中定义:tc.hol.labinfo.attendee.attendlabbutton=Lab'eKat

 

              <INPUT TYPE="button" name="InviteAttendees" value="<bean:message key='tc.hol.labinfo.attendee.attendlabbutton'/>" onClick="SubmitOK(this.form,'AttendLab');">

                            

上述在jsp中显示  Lab'eKat

 

          <INPUT TYPE="button" name="InviteAttendees" value='<bean:message key="tc.hol.labinfo.attendee.attendlabbutton"/>' onClick="SubmitOK(this.form,'AttendLab');">

 

       上述在jsp中显示  Lab,其中'eKat被过滤掉。

你可能感兴趣的:(struts1)