No result defined for action action.FileDownLoadAction and result downSuccess
? ? ? ? <action name="FileDownLoad_execute" class="action.FileDownLoadAction">
<param name="inputPath">/source/${downloadName}</param> ?
<result name="downSuccess" type="stream">
<param name="contentType">application/octet-stream</param>
<param name="inputName">inputStream</param>
<param name="contentDisposition">attachment;filename="${downloadName}"</param>
<param name="bufferSize">8192</param>
</result>
? ? ? ? </action>
明明配置了啊 ?struts 用的2.3.3
2017-02-04
然后還有一個問題是 ?如果namespace不為根目錄的話 比如="/model/other" ?一定要在
<a ?href="<%=path%>/model/other/FileDownLoad"/>中加入全路徑?
否則一直報
No result defined for action action.FileDownLoadAction and result downSuccess
2017-02-04
找到了問題 ?控制臺輸出了
Invalid character found in the request target.?The valid characters are defined in RFC 7230 and RFC 3986
tomcat8.5的問題 添加了一些驗證
原因是在url中傳遞中文導致的