• 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

Where to put beans for JSP

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Apologies if this really obvious.

I've just started playing about with JSP on Apache Web Server.

I've managed to get servlets running by placing them in file: Tomcat 6.0\webapps\examples\WEB-INF\classes. What I want to do however is call Java classes that I've constructed myself, for use in JSP scriptlets.

I can't figure out as to where I need to put the compiled classes though, which allows them to be called for use in JSP.

Is their anyone whose familiar with Apache Tomcat able to help?
[ November 02, 2007: Message edited by: Bear Bibeault ]
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by And Green:
I've just started playing about with JSP on Apache Web Server.


I assume you mean Apache Tomcat. The Apache Web Server is a different project that does not support JSP.

I can't figure out as to where I need to put the compiled classes though, which allows them to be called for use in JSP.


Same place as the servlets. Just be sure that all beans are in a package other than the default.

Is their anyone whose familiar with Apache Tomcat able to help?


This is not Tomcat-specific and will be true for all JSP containers. I have adjusted the topic title accordingly.
[ November 02, 2007: Message edited by: Bear Bibeault ]
 
And Green
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks alot for that. Very quick too!

I'll give it a go.
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My pleasure. Be sure to mind the part about the packages.
 
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please do place the pakagae compiled bean classes in the classes folder.

I believe Server does not matter what ever we use. Because the context is important for us.

Every web context should have the same context.

context(all the jsp files and htmls)
in this folder WEB-INF/classes(*.class) files. and web.xml along with classes folder.

Thanks

Jetendra
 
And Green
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yep, worked a treat. This website is great.
 
What's brown and sticky? ... a stick. Or a tiny ad.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic