Hi! I'm not sure if this advice will work for you; it works for Tomcat 4.1.x but I don't know if Tomcat 5.0 works the same as 4.1.x.
1. Check your tomcat-users.xml file and make sure that at least one of the entries there has the authority to use the manager application. For example, this will configure the user id 'tomcat' with the password 'tomcat' to be able to use the Manager application: <?xml version='1.0' encoding='utf-8'?> <tomcat-users> <role rolename="tomcat"/> <role rolename="standard"/> <role rolename="manager"/> <user username="tomcat" password="tomcat" roles="tomcat,standard,manager"/> </tomcat-users> 2. Start Tomcat. If you're not sure how, use the startup.bat file in the \bin directory for Windows and startup.sh for Unix. If this works, you'll see the Tomcat welcome page. 3. Start the Manager application by clicking on the Tomcat Manager link on the Tomcat welcome page. If you set up the tomcat-users.xml file correctly, supply the userid and password of an ID that has manager authority. (In my example, the user is 'tomcat' and the password is 'tomcat'). 4. Go to the bottom of the Manager page, to the section marked: "Upload a WAR file to install". Click the "Browse...." button and navigate through your file system until you have selected the WAR file that you want to install. Press the "Install" button. After a few seconds, your servlet should have been added to the Applications table near the top of the page and you should get a message saying that the application was successfully installed at such-and-such a context. Assuming that there are no problems, Step 4 will copy your WAR file to the Webapps directory and unpack your WAR file into a subdirectory of Webapps with the same name as the servlet context. To execute your servlet, use your browser to start it. For example: http://localhost:8080/MyServlet/form where Tomcat is on your own computer (not a remote one), your context name is 'MyServlet' and 'form' is a specific url-pattern in the web.xml file that you put in the WAR file. I hope this helps. Rhino ----- Original Message ----- From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, December 12, 2003 7:48 AM Subject: How can I add a servlet to a server? Hello! I installed Tomcat 5.0. Please send me the answer. I will have my servlet in a directory "mydir" 1. under "webapps". 2. out of the "webapps" but under CATALINA_HOME. 3. or out of that. Best Mehdi Shahpar Herder Strasse 4 12163 Berlin __________________________________________________________________ Turbospeed zum Turbopreis! Surfen Sie doch auch mit der DSL-Flatrate von Tiscali. Nur 15,90 EUR im Monat. Tiscali DSL basiert auf dem T-DSL-Anschluss der Deutschen Telekom AG, durch den weitere Kosten entstehen. Dieser ist in vielen Anschlussgebieten verf�gbar. 6 Monate Mindestvertragslaufzeit. Und falls Sie wider Erwarten im ersten Monat nicht zufrieden sein sollten, gewährt Tiscali Ihnen ein sofortiges Kündigungsrecht und Sie erhalten Ihr Geld zurück. Klicken Sie hier: http://registrierung.tiscali.de/produkte/1342_dslflatrate.php?akkcode=10253 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
