You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by jhayden <ja...@hayden1.fsnet.co.uk> on 2007/08/31 12:10:14 UTC
Using own index.html in $CATALINA_HOME/webapps/ROOT directory
After changing port to 80 attempting to use Tomcat as a HTTP server as well
as
a container.
When entering http:\\localhost I am getting the standard Tomcat display.
However its being drawn from the index.jsp rather than the index.html due
the message on the page detailing
"$CATALINA_HOME/webapps/ROOT/index.jsp"
What I have attempted to do is place my own static html files in the
C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\ROOT
directory.
Basically expecting my index.html to be displayed. However it only attempts
to display the index.jsp page.
I have tried commenting out the - <welcome-file>index.jsp</welcome-file>
from the web.xml but this does not make any difference.
I want to use the ROOT directory and force the index.html to be used.
All i get is a Error 404 message.
Can anyone help me please?
--
View this message in context: http://www.nabble.com/Using-own-index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-tf4359312.html#a12423852
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by Mark Thomas <ma...@apache.org>.
jhayden wrote:
>> Is this a clean install?
>>
>> Mark
>>
>> ---------------------------------------------------------------------
> Yes. Brand new.
> Without changing anything in ROOT, if I comment out the index.jsp from the
> web.xml file it gives me a 404 Error. As soon as I un-comment the line it
> works fine. Therefore its only interested in using the index.jsp?
For a clean Tomcat 6 install, you can just edit index.html and the
changes will be reflected instantly.
I noticed there is index.jsp and index.html. The jsp probably needs to
be removed from the build.
Mark
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by jhayden <ja...@hayden1.fsnet.co.uk>.
Mark Thomas-15 wrote:
>
> jhayden wrote:
>> Tried that but still getting the error.
>> I only left the default index.html file there and it still gives me the
>> 404
>> Error.
>> It appears that it only wants to use the index.jsp file?
>
> The default welcome file list is index.html. index.htm, index.jsp. In
> that order.
>
> Is this a clean install?
>
> Mark
>
> ---------------------------------------------------------------------
> Yes. Brand new.
> Without changing anything in ROOT, if I comment out the index.jsp from the
> web.xml file it gives me a 404 Error. As soon as I un-comment the line it
> works fine. Therefore its only interested in using the index.jsp?
>
>
--
View this message in context: http://www.nabble.com/Using-own-index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-tf4359312.html#a12443155
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by Mark Thomas <ma...@apache.org>.
jhayden wrote:
> Tried that but still getting the error.
> I only left the default index.html file there and it still gives me the 404
> Error.
> It appears that it only wants to use the index.jsp file?
The default welcome file list is index.html. index.htm, index.jsp. In
that order.
Is this a clean install?
Mark
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by jhayden <ja...@hayden1.fsnet.co.uk>.
Tried that but still getting the error.
I only left the default index.html file there and it still gives me the 404
Error.
It appears that it only wants to use the index.jsp file?
--
View this message in context: http://www.nabble.com/Using-own-index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-tf4359312.html#a12424931
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by Mark Thomas <ma...@apache.org>.
jhayden wrote:
> I want to use the ROOT directory and force the index.html to be used.
> All i get is a Error 404 message.
Delete the contents of ROOT (jsps, WEB-INF, etc) apart from your
files. You might need to reload the ROOT web application although I am
fairly sure the default configuration will detect the change and
reload the webapp for you.
Note: Tomcat 6 treats any directory in webapps as a web application.
HTH,
Mark
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by jhayden <ja...@hayden1.fsnet.co.uk>.
I ended up uninstalling tomcat and then reinstalling it.
It works fine now.........Very odd. Thanks for you help.
Victor Lutin wrote:
>
> Hi,
>
> Well, what web.xml file you modified?
>
> CATALINA_HOME = C:\Program Files\Apache Software Foundation\Tomcat 6.0\
>
> 1. %CATALINA_HOME%/conf/web.xml
> 2. %CATALINA_HOME%/webapps/ROOT/WEB-INF/web.xml
>
> I have Tomcat 6 installed, i tried to do that, and works for me, You
> most comment web.xml in opction 1. and verify web.xml in option 2 for
> <welcome-file>.
>
> I got 404 error when I put a URL like this on my browser: (8180 is
> my port for tomcat)
>
> http://localhost:8180/ROOT/
> but with
> http://localhost:8180
>
> loads my new Index.html.
>
> VL.
>
>
>
> On Aug 31, 2007, at 4:10 AM, jhayden wrote:
>
>>
>> After changing port to 80 attempting to use Tomcat as a HTTP server
>> as well
>> as
>> a container.
>> When entering http:\\localhost I am getting the standard Tomcat
>> display.
>> However its being drawn from the index.jsp rather than the
>> index.html due
>> the message on the page detailing
>> "$CATALINA_HOME/webapps/ROOT/index.jsp"
>>
>> What I have attempted to do is place my own static html files in the
>> C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\ROOT
>> directory.
>> Basically expecting my index.html to be displayed. However it only
>> attempts
>> to display the index.jsp page.
>>
>> I have tried commenting out the - <welcome-file>index.jsp</welcome-
>> file>
>> from the web.xml but this does not make any difference.
>> I want to use the ROOT directory and force the index.html to be used.
>> All i get is a Error 404 message.
>> Can anyone help me please?
>>
>> --
>> View this message in context: http://www.nabble.com/Using-own-
>> index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-
>> tf4359312.html#a12423852
>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/Using-own-index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-tf4359312.html#a12660513
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Using own index.html in $CATALINA_HOME/webapps/ROOT directory
Posted by Victor Lutin <vl...@bytesw.com>.
Hi,
Well, what web.xml file you modified?
CATALINA_HOME = C:\Program Files\Apache Software Foundation\Tomcat 6.0\
1. %CATALINA_HOME%/conf/web.xml
2. %CATALINA_HOME%/webapps/ROOT/WEB-INF/web.xml
I have Tomcat 6 installed, i tried to do that, and works for me, You
most comment web.xml in opction 1. and verify web.xml in option 2 for
<welcome-file>.
I got 404 error when I put a URL like this on my browser: (8180 is
my port for tomcat)
http://localhost:8180/ROOT/
but with
http://localhost:8180
loads my new Index.html.
VL.
On Aug 31, 2007, at 4:10 AM, jhayden wrote:
>
> After changing port to 80 attempting to use Tomcat as a HTTP server
> as well
> as
> a container.
> When entering http:\\localhost I am getting the standard Tomcat
> display.
> However its being drawn from the index.jsp rather than the
> index.html due
> the message on the page detailing
> "$CATALINA_HOME/webapps/ROOT/index.jsp"
>
> What I have attempted to do is place my own static html files in the
> C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\ROOT
> directory.
> Basically expecting my index.html to be displayed. However it only
> attempts
> to display the index.jsp page.
>
> I have tried commenting out the - <welcome-file>index.jsp</welcome-
> file>
> from the web.xml but this does not make any difference.
> I want to use the ROOT directory and force the index.html to be used.
> All i get is a Error 404 message.
> Can anyone help me please?
>
> --
> View this message in context: http://www.nabble.com/Using-own-
> index.html-in-%24CATALINA_HOME-webapps-ROOT-directory-
> tf4359312.html#a12423852
> Sent from the Tomcat - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org