----------------------------------------------------------------
BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
WHEN YOU POST, include all relevant version numbers, log files,
and configuration files. Don't make us guess your problem!!!
----------------------------------------------------------------
I thank each and every one of you. Adding the path to the wrapper.class in
jserv.properties fixed it. I appreciate it, and I'll try not to ask such
simplistic questions until I get a better understanding of jserv's config
files.
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of Joe Sheble
> a.k.a. Wizaerd
> Sent: Friday, July 21, 2000 8:58 AM
> To: Java Apache Users
> Subject: touble connecting to mySQL
>
>
> ----------------------------------------------------------------
> BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
> WHEN YOU POST, include all relevant version numbers, log files,
> and configuration files. Don't make us guess your problem!!!
> ----------------------------------------------------------------
>
> I've recently installed ApacheJServ 1.1.2 and it's working. And I've
> recently downloaded the mySQL JDBC driver as well. In trying to run the
> following code, I get the error unable to load driver error. I'm not real
> sure what I should be checking. I've included my CLASSPATH as well as the
> directory structure to the drivers. Could anybody point me in the right
> direction as to what I should be checking?
>
>
> import java.io.*;
> import java.sql.*;
> import javax.servlet.*;
> import javax.servlet.http.*;
>
> /**
> * This is a simple example of an HTTP Servlet. It responds to the GET
> * and HEAD methods of the HTTP protocol.
> */
> public class Hello extends HttpServlet
>
> /**
> * Handle the GET and HEAD methods by building a simple web page.
> * HEAD is just like GET, except that the server returns only the
> * headers (including content length) not the body we write.
> */
> public void doGet (HttpServletRequest request,
> HttpServletResponse response)
> throws ServletException, IOException
> {
> PrintWriter out;
> String title = "Example Apache JServ Servlet";
>
> // set content type and other response header fields first
> response.setContentType("text/html");
>
> // then write the data of the response
> out = response.getWriter();
>
> try {
>
> // The newInstance() call is a work around for some
> // broken Java implementations
>
> Class.forName("org.gjt.mm.mysql.Driver").newInstance();
>
> }
> catch (Exception E) {
> out.println("Unable to load driver.");
> E.printStackTrace();
> }
>
>
> out.println("<HTML><HEAD><TITLE>");
> out.println(title);
> out.println("</TITLE></HEAD><BODY bgcolor=\"#FFFFFF\">");
> out.println("<H1>" + title + "</H1>");
> out.println("<H2> Congratulations, ApacheJServ 1.1.2
> is working!<br>");
> out.println("</BODY></HTML>");
> out.close();
> }
> }
>
>
>
> CLASSPATH=.:/usr/local/jdk/lib/classes.zip:/usr/local/jdk/mySQL:/u
> sr/local/JServ/libexec/ApacheJServ.jar:/usr/local/jsdk/lib/jsdk.jar
>
> 4 directories, 37 files
> [root@Gandalf mySQL]# tree > tree.out
> [root@Gandalf mySQL]# less tree.out
>
>
> --
> --------------------------------------------------------------
> Please read the FAQ! <http://java.apache.org/faq/>
> To subscribe: [EMAIL PROTECTED]
> To unsubscribe: [EMAIL PROTECTED]
> Search Archives:
> <http://www.mail-archive.com/java-apache-users%40list.working-dogs.com/>
> Problems?: [EMAIL PROTECTED]
--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search Archives:
<http://www.mail-archive.com/java-apache-users%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]