Thanks for responding Dragon. I added the JavaScript mime type to the HTTPD
file. I restarted the server and tried to load the external JavaScript
file into the .CGI process from the supra-directory (root) and a
subdirectory to the cgi-bin directory. The load from the root did not
work. The load from the subdirectory tried to work but attempted to
execute the .JS file like a Perl/CGI program according to the Apache log.
The content type is given as below.
<script type='text/JavaScript' src='js/rnd.js'></script>
I need more guidance.
Thanks again.
craigt
Dragon-4 wrote:
>
> CraigT wrote:
>
>>Hello,
>>
>>I've built an app with Perl (5.8)/CGI, Javscript, and CSS. Its running on
a
>>Windows XP Home (development box) using Apache 2. It is being handled by
>>mod_perl 2 with no errors.
>>
>>My problem is that I can't load .JS files into Perl/CGI scripts running
out
>>of the cgi-bin directory using the '<script SRC=' method. I can't load a
>>.JS file from a supra-, the cgi-bin, or a sub- directory. I have no
problem
>>loading a .JS file in this way into a process executing out of the root
>>directory - the parent to the cgi-bin directory. I'm thinking I have not
>>done something needed in the Apache HTTPD? Can anyone help me. Thanks
in
>>advance.
>>
>>Respectfully,
>>craigt
> ---------------- End original message. ---------------------
>
> Your http server is probably configured to run anything in the
> cgi-bin directory as a CGI script. So what is probably happening is
> that the server is attempting to execute these js files and failing.
> If that is the case, you should see log entries in the error log
> regarding these failures.
>
> You need to serve these files out of a different directory and you
> also need to make sure that the mime type for them is properly
> configured. This is because the server must serve them and not
> execute them and the browser should be given the correct content type
> when the file is served.
>
> Dragon
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Venimus, Saltavimus, Bibimus (et naribus canium capti sumus)
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> " from the digest: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
--
View this message in context:
http://www.nabble.com/Can%27t-load-.JS-file-into-Perl-CGI-script.-tp14422533p14435186.html
Sent from the Apache HTTP Server - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
" from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]