开发者

Access file in weblogic server

Is there a folder in the Domain Directory of Weblogic, where files put inside can be accessed directly from web browser? In other word, I do开发者_如何学Cn't have to pack the file in an ear, war file and deploy it to make it accessible? Thank you very much Regards K.


The Virtual Directory Mapping feature (that you declare in the weblogic.xml) would do the trick:

Using the virtual directory mapping feature, you can create one directory to serve static files such as images for multiple Web Applications. For example, you would create a mapping similar to the folowing:

<virtual-directory-mapping>
  <local-path>c:/usr/gifs</local-path>
  <url-pattern>/images/*</url-pattern>
</virtual-directory-mapping>

A request to http://localhost:7001/mywebapp/images/test.gif will cause your WebLogic Server implementation to look for the requested image at: c:/usr/gifs/images/*.

This directory must be located in the relative uri, such as "/images/test.gif".

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜