What are you trying to do and why are you trying to do it?
When you hide your JSPs under the WEB-INF, it's usually because you don't want
the user to access them directly.  With your <script src="xyz.js">, you're
telling the browser to access that file.  If you then put it under WEB-INF,
you're telling the server not to serve that file.  You can't go both ways. 
Anything you place under WEB-INF won't be accessible to the browser/user, and
that includes your .js file.

--- Colin Foulkes <[EMAIL PROTECTED]> wrote:
> Hi,
> 
> I'm quite new to Open source and Struts
> 
> I'm trying to convert some Microsoft asp.net pages to a struts/apache
> environment; and following advice on the newgroup, have "hidden" my .jsp pages
> in directories beneath /WEB-INF.
> 
> However, I have some pages that include script tags for loading javascript
> files. When I place the .js files under the WEB-INF directory they are not
> accessible to my page.
> 
> The jsp page contains...
> <script src=/WEB-INF/scripts/XXX.js>
> The output window for local host access (under netbeans ide) shows the
> following...
> "GET /WEB-INF/scripts/XXX.js HTTP/1.1" 404 720
> 
> If I move the scripts directory out from under WEB-INF, the page loads fine, 
> the log shows the following
> "GET /scripts/XXX.js HTTP/1.1" 304 -
> 
> 
> Is there a way to do this? To hide javascript files under WEB-INF and access
> them from the jsp pages?
> 
> Thanks in advance,
> 
> Colin
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to