• 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
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

running jforum witht another directory structure

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey,

i would like to run jforum witht another directory structure in oder to integrate it in an existing web-app later. So i have this directory structure in my root (forum) folder:


.settings
WebContent
    images
    META-INF
    src
        net
                jforum
    templates
    Web-Inf
        classes
        config
        lib
        web.xml
        ...
    index.htm
.classpath
.project


my web.xml is unchanged. In fact, i have keeped the same directory structure from the webContent root down. the .class files are generated in >Web-Inf >classes , so i think every thing is ok.
But When in run the forum (http://localhost:8080/forum/index.htm) i get the error "the ressource forum/index.htm ist not available".
I use a mysql database and tomcat 5.0.

Can you help me please?
thanks.



[originally posted on jforum.net by webparcours]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not quite sure what you are trying to do here. This looks like a development layout and not a webapp layout.

That said, JForum can be integrated with other apps but it's directory structure and WEB-INF files need to stay located off the main webapp directory. E.g, with TC this is either a directory under the webapps directory or as specified in the deployment xml.

FWIW, I think you'll probably want to have a layout without the src under the WebContent directory. I'd suggest something like:

src/java/jforum/<jforum src tree> => Compiles to WebContent/Web-inf/classes
src/java/myapp/<my app src tree> => Compiles to WebContent/Web-inf/classes
WebContent
<jforum directories>
<my app directories>
WEB-INF
web.xml (merger of myapp and jforum)
<jforum directories>
lib
<jforum jars>
<myapp jars>

Then use the Tomcat deployment XML to point the webapp doc root to the WebContent directory. With TC 5.5. this mean creating an xml file with the webapp name (e.g. forums or myapp) in your conf/Catalina/localhost (or host name) that looks like:



This will tell TC that the URI /myapp will find it's content in the WebContent directory. The reloadable attribute will make TC reload the application anytime the class files change.

Note: If 5.0 may use a different syntax for doing this... they changed thing either in 5.0 or 5.5... check the docs if you are not using 5.5.
[originally posted on jforum.net by monroe]
 
We cannot change unless we survive, but we will not survive unless we change. Evolving tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic