• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

running servlets in WTE

 
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
try action="/servlet/com.myservletname" in your html page. servlet should be in /servlet directory of webapp.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic