• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

running servlets in WTE

 
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone tell me how to run servlets in the WTE
I have them in VAJ
where do i put my HTML files etc....
thank you
 
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
\VisualAge for Java\ide\project_resources\IBM WebSphere Test Environment\hosts\default_host\default_app\servlets\
should contain servlet classes

\VisualAge for Java\ide\project_resources\IBM WebSphere Test Environment\hosts\default_host\default_app\web\
should contain JSP or HTML

I don't remember where exactly, but there is a step-by-step in the online help of VAJ to help you during testing process
 
Fred Abbot
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you ---
so now when i run http:\\localhost:8080 my first page comes up but then when i try to hit a servlet from there it cant find the servlet???

[This message has been edited by Fred Abbot (edited December 12, 2001).]
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Fred Abbot:
Thank you ---
so now when i run http:\\localhost:8080 my first page comes up but then when i try to hit a servlet from there it cant find the servlet???

[This message has been edited by Fred Abbot (edited December 12, 2001).]


In WTE, if you do not add any special mapping in a .xml file, you have to call the servlet using the package full name.
ie : http://localhost/mywebapp/com.mycomp.myproject.myservlet
Is it the syntax you use to call the servlet ?
 
Fred Abbot
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
actually that is not the way i call my servlet
it is called by my HTML page which is in the web folder of the WTE and i call by /package name/directory/directory/etc..
but it cant find the first directory
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Fred Abbot:
actually that is not the way i call my servlet
it is called by my HTML page which is in the web folder of the WTE and i call by /package name/directory/directory/etc..
but it cant find the first directory



I've made a mistake yesterday.
All apologizes.
You can call your servlet adding the /servlet/ in the url.
FORM method=POST ACTION="/servlet/com.mycompany.myServlet
Then your servlet has to be in the following folder :
"\VisualAge for Java\ide\project_resources\IBM WebSphere Test Environment\hosts\default_host\default_app\servlets\com\mycompany\"
[This message has been edited by Bill Bailey (edited December 14, 2001).]
[This message has been edited by Bill Bailey (edited December 14, 2001).]
 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
try action="/servlet/com.myservletname" in your html page. servlet should be in /servlet directory of webapp.
 
Yeah. What he said. Totally. Wait. What? Sorry, I was looking at this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic