LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Javascript problems on Apache (https://www.linuxquestions.org/questions/linux-newbie-8/javascript-problems-on-apache-73445/)

vvandam 07-17-2003 12:33 AM

Javascript problems on Apache
 
HI All

My Javascript that was working from an IIS web server is not working from the Apache web server.

Does IIS and Apache host Javascript files differently?


-----------
vvandam

:D :D :D

pnh73 07-17-2003 03:07 AM

When you say "Javascript" do you mean ones that are parsed on the Server Side? or are they run by Internet explorer? (i.e. within the HTML)

vvandam 07-17-2003 03:21 AM

The Javascript is passed on the server side.

pnh73 07-17-2003 06:36 AM

I have just found this, and I think it may help you. You need to use some software called Tomcat. Here are some instructions I found to install and configure it:

(Obtained from http://forums.devshed.com/archive/9/2001/06/3/16972)

Quote:

OK, here is how you do it - be sure you have the lastest versions of both:

1.) Install Apache that is is able to laod modules dynamically. mod_so needs to be built in.

2.) Install Tomcat.

3.) Load mod_jk into apache. You can get it from jakarta.apache.org. In your httpd.conf:
Code:

LoadModule jk_module libexec/mod_jk.so
4.) edit your httpd.conf, append this text:
Code:


<IfModule mod_jk.c>
JkWorkersFile *PATH-TO-TOMCAT*/conf/workers.properties
JkLogFile *PATH-TO-APACHE*/logs/mod_jk.log
JkLogLevel error
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
</IfModule>

5.) Edit server.xml of Tomcat. Create a new Context:
Code:


<Context path=""
docBase="*PATH-TO-APACHE*/htdocs"
crossContext="true"
debug="0"
reloadable="true"
trusted="false" >
</Context>

This is the most important Part! You Context's docbase points to the same directory as Apache's document-root.

6. ) Still server.xml: uncomment these lines:
Code:


<Connector className="org.apache.tomcat.service.PoolTcpConnector">
<Parameter name="handler" value="org.apache.tomcat.service.connector.Ajp13ConnectionHandler"/>
<Parameter name="port" value="8009"/>
</Connector>

7.) Start Tomcat first, then Apache

For test-purposes, put a file test.jsp into the htdocs-folder:

Code:


<%= new java.util.Date() %>


HTH

Paul

vvandam 07-17-2003 06:50 AM

Thanx

I have tried it and it does not seem to be doing anything.

It also looks like one of the files on my web server was refering to another Javascript on another web server wich was not availlable until now. I have contacted that administrator to request a copy of the Javascript that my server is referncing. Once I have it, I can modify all my pages to refer to the correct locations.

Thanx again for all the help.


------------
vvandam
:D :D :D


All times are GMT -5. The time now is 05:16 PM.