Koon Yue Lam wrote:
Hi, I want to protect my JSP from direct access, so they can only
access by Struts action.
but....
If I want to include some Javascript or CSS to a JSP, I can't !
Because .js and .css needed to place directly under WebRoot
I'm afraid I don't understand the issue.
If you're putting your JS and CSS in an externally-accessible place
(maybe /scripts and /styles) then the standard HTML references for
"external" resources:
<link rel="stylesheet" type="text/css" href="/styles/example.css"/>
<style type="text/css">@import "/styles/example.css";</style>
<script type="text/javascript" src="/scripts/example.js"></script>
:: will work fine.
The client UA can access them directly (and cache them, which is
usually a desirable behavior).
HTH,
--
Hassan Schroeder ----------------------------- [EMAIL PROTECTED]
Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com
dream. code.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]