Re: webpage & servlets !
How are you referring to the link in your html or jsp page? Swapneel Dange wrote: hi there ! i am running a servlet, which takes the username and then the password and opens another webpage in the browser , my servlet is under the webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage are not inside the directory known as classes( i am generating a webpage by making a .txt file first and then making a .html file out of that) the .txt and .html files are under webapps/ROOT/dange/ , and whenever i try to access the .txt files, i get some error like tha one i am sending here. can anybody help me on this ! java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange _ Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
i am accesing the webpage inside the SERVLET itself. and i am trying to access them as normal webpage and normal .txt page, but the .txt page is then made into a .html page. And there is no link as such on nay page for the webpage i am trying to access. i am accessing them through the html tags inside the servlet itself. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Peng Tuck Kwok <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Mon, 17 Feb 2003 14:30:07 +0800 How are you referring to the link in your html or jsp page? Swapneel Dange wrote: hi there ! i am running a servlet, which takes the username and then the password and opens another webpage in the browser , my servlet is under the webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage are not inside the directory known as classes( i am generating a webpage by making a .txt file first and then making a .html file out of that) the .txt and .html files are under webapps/ROOT/dange/ , and whenever i try to access the .txt files, i get some error like tha one i am sending here. can anybody help me on this ! java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange _ Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
I do not see why you cannot access a directory under a legit webapp, much less get the text file you put in there. Can you please send your servlet code ? Swapneel Dange wrote: i am accesing the webpage inside the SERVLET itself. and i am trying to access them as normal webpage and normal .txt page, but the .txt page is then made into a .html page. And there is no link as such on nay page for the webpage i am trying to access. i am accessing them through the html tags inside the servlet itself. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Peng Tuck Kwok <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Mon, 17 Feb 2003 14:30:07 +0800 How are you referring to the link in your html or jsp page? Swapneel Dange wrote: hi there ! i am running a servlet, which takes the username and then the password and opens another webpage in the browser , my servlet is under the webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage are not inside the directory known as classes( i am generating a webpage by making a .txt file first and then making a .html file out of that) the .txt and .html files are under webapps/ROOT/dange/ , and whenever i try to access the .txt files, i get some error like tha one i am sending here. can anybody help me on this ! java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange _ Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webpage & servlets !
I think you've got your terminology a little mixed up. "Accessing them through the HTML tags inside the servlet itself" isn't possible. If you mean that your servlet generates HTML text that is sent to the browser, and some of that HTML text refers to the page you are looking for, then the URL needs to be a URL that the client browser can resolve, that is something like http://www.host.com/myWebApp/somepage.html. If you mean that your servlet is trying to read the file that is sitting on your hard drive, using some sort of Java File object, then you need to refer to the file in a filesystem-related manner, such as "myWebApp/somepage.html". In either case, you will get much faster (and more accurate) help if you: 1) explain exactly what it is you want to do, and 2) post the code that you've written that is trying to do it, and 3) describe the manner (URL) you're using to execute that servlet code, and 4) post the error message you get when you execute that code John > -Original Message- > From: Swapneel Dange [mailto:[EMAIL PROTECTED]] > Sent: Monday, February 17, 2003 2:32 AM > To: [EMAIL PROTECTED] > Subject: Re: webpage & servlets ! > > > i am accesing the webpage inside the SERVLET itself. and i am > trying to > access them as normal webpage and normal .txt page, but the > .txt page is > then made into a .html page. > > And there is no link as such on nay page for the webpage i am > trying to > access. i am accessing them through the html tags inside the > servlet itself. > > > Swapneel Dange > 505-642-4126 > http://www.cs.nmsu.edu/~sdange > > > > > > >From: Peng Tuck Kwok <[EMAIL PROTECTED]> > >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> > >To: Tomcat Users List <[EMAIL PROTECTED]> > >Subject: Re: webpage & servlets ! > >Date: Mon, 17 Feb 2003 14:30:07 +0800 > > > >How are you referring to the link in your html or jsp page? > > > >Swapneel Dange wrote: > >>hi there ! > >> > >>i am running a servlet, which takes the username and then > the password and > >>opens another webpage in the browser , my servlet is under the > >>webapps/ROOT/WEB-INF/classes but my .txt file for running > the webpage are > >>not inside the directory known as classes( i am generating > a webpage by > >>making a .txt file first and then making a .html file out of that) > >> > >>the .txt and .html files are under webapps/ROOT/dange/ , > and whenever i > >>try to access the .txt files, i get some error like tha one > i am sending > >>here. > >> > >>can anybody help me on this ! > >> > >> > >>java.io.FileNotFoundException: > >>C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapp > s\ROOT\dange\frame0.html > >>(The system cannot find the path specified) > >> > >> > >> > >>Swapneel Dange > >>505-642-4126 > >>http://www.cs.nmsu.edu/~sdange > >> > >> > >> > >> > >>_ > >>Help STOP SPAM with the new MSN 8 and get 2 months FREE* > >>http://join.msn.com/?page=features/junkmail > >> > >> > >> > - > >>To unsubscribe, e-mail: [EMAIL PROTECTED] > >>For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > > >- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > _ > Add photos to your e-mail with MSN 8. Get 2 months FREE*. > http://join.msn.com/?page=features/featuredemail > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
Swapneel Dange wrote: java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Arrgh! Swapneel ! Look at the directory ! Unless you have a jakarta-tomcat directory under ANOTHER jakarta-tomcat directory, I do believe you have a typo error !! Regards, chong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
yeah, there is the servlet code as an attachment to this mail. and ther hierarchy for the servlet classes are as folllows : webapps ROOT dange frame0.txt frame0.html frame1.html WEB-INF classes ranade SubmitServlet.java SubmitServlet.class and all other supporting class files. i am not able to understand the meaning of the error such as the following : java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) although it says that FILE NOT FOUND, but i am pretty sure that the FILE is there in the directory, anyways.. ! Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Peng Tuck Kwok <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Mon, 17 Feb 2003 15:55:58 +0800 I do not see why you cannot access a directory under a legit webapp, much less get the text file you put in there. Can you please send your servlet code ? Swapneel Dange wrote: i am accesing the webpage inside the SERVLET itself. and i am trying to access them as normal webpage and normal .txt page, but the .txt page is then made into a .html page. And there is no link as such on nay page for the webpage i am trying to access. i am accessing them through the html tags inside the servlet itself. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Peng Tuck Kwok <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Mon, 17 Feb 2003 14:30:07 +0800 How are you referring to the link in your html or jsp page? Swapneel Dange wrote: hi there ! i am running a servlet, which takes the username and then the password and opens another webpage in the browser , my servlet is under the webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage are not inside the directory known as classes( i am generating a webpage by making a .txt file first and then making a .html file out of that) the .txt and .html files are under webapps/ROOT/dange/ , and whenever i try to access the .txt files, i get some error like tha one i am sending here. can anybody help me on this ! java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange _ Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail SubmitServlet.java Description: java/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
hey CHONG ! ur right man, its kind of weird but i do have a jakarta directory under a jakarta directory. i am not at all mistaken in the directory path description i guess. anyway thanx for reminding to take a look at the directory stucture i have defined. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Chong Yu Meng <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Mon, 17 Feb 2003 22:03:16 +0800 Swapneel Dange wrote: java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) Arrgh! Swapneel ! Look at the directory ! Unless you have a jakarta-tomcat directory under ANOTHER jakarta-tomcat directory, I do believe you have a typo error !! Regards, chong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webpage & servlets !
your servlet should also be under classes, not under WEB-INF Filip ~ Namaste - I bow to the divine in you ~ Filip Hanik Software Architect www.filip.net >-Original Message- >From: Swapneel Dange [mailto:[EMAIL PROTECTED]] >Sent: Monday, February 17, 2003 10:12 AM >To: [EMAIL PROTECTED] >Subject: Re: webpage & servlets ! > > >yeah, there is the servlet code as an attachment to this mail. and ther >hierarchy for the servlet classes are as folllows : > >webapps > ROOT > dange > frame0.txt > frame0.html > frame1.html > WEB-INF > classes > ranade > SubmitServlet.java > SubmitServlet.class and all other supporting class files. > >i am not able to understand the meaning of the error such as the >following : > >java.io.FileNotFoundException: >C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\ >dange\frame0.html >(The system cannot find the path specified) > >although it says that FILE NOT FOUND, but i am pretty sure that >the FILE is >there in the directory, anyways.. ! > >Swapneel Dange >505-642-4126 >http://www.cs.nmsu.edu/~sdange > > > > > > > > > > > >>From: Peng Tuck Kwok <[EMAIL PROTECTED]> >>Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >>To: Tomcat Users List <[EMAIL PROTECTED]> >>Subject: Re: webpage & servlets ! >>Date: Mon, 17 Feb 2003 15:55:58 +0800 >> >>I do not see why you cannot access a directory under a legit webapp, much >>less get the text file you put in there. >> Can you please send your servlet code ? >> >>Swapneel Dange wrote: >>>i am accesing the webpage inside the SERVLET itself. and i am trying to >> >>>access them as normal webpage and normal .txt page, but the .txt page is >>>then made into a .html page. >>> >>>And there is no link as such on nay page for the webpage i am trying to >>>access. i am accessing them through the html tags inside the servlet >>>itself. >>> >>> >>>Swapneel Dange >>>505-642-4126 >>>http://www.cs.nmsu.edu/~sdange >>> >>> >>> >>> >>> >>>>From: Peng Tuck Kwok <[EMAIL PROTECTED]> >>>>Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >>>>To: Tomcat Users List <[EMAIL PROTECTED]> >>>>Subject: Re: webpage & servlets ! >>>>Date: Mon, 17 Feb 2003 14:30:07 +0800 >>>> >>>>How are you referring to the link in your html or jsp page? >>>> >>>>Swapneel Dange wrote: >>>> >>>>>hi there ! >>>>> >>>>>i am running a servlet, which takes the username and then the password >>>>>and opens another webpage in the browser , my servlet is under the >>>>>webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage >>>>>are not inside the directory known as classes( i am generating >a webpage >>>>>by making a .txt file first and then making a .html file out of that) >>>>> >>>>>the .txt and .html files are under webapps/ROOT/dange/ , and >whenever i >>>>>try to access the .txt files, i get some error like tha one i >am sending >>>>>here. >>>>> >>>>>can anybody help me on this ! >>>>> >>>>> >>>>>java.io.FileNotFoundException: >>>>>C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\R >OOT\dange\frame0.html >>>>>(The system cannot find the path specified) >>>>> >>>>> >>>>> >>>>>Swapneel Dange >>>>>505-642-4126 >>>>>http://www.cs.nmsu.edu/~sdange >>>>> >>>>> >>>>> >>>>> >>>>>_ >>>>>Help STOP SPAM with the new MSN 8 and get 2 months FREE* >>>>>http://join.msn.com/?page=features/junkmail >>>>> >>>>> >>>>>- >>>>>To unsubscribe, e-mail: [EMAIL PROTECTED] >>>>>For additional commands, e-mail: [EMAIL PROTECTED] >>>>> >>>>> >>>> >>>> >>>> >>>>- >>>>To unsubscribe, e-mail: [EMAIL PROTECTED] >>>>For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> >>>_ >>>Add photos to your e-mail with MSN 8. Get 2 months FREE*. >>>http://join.msn.com/?page=features/featuredemail >>> >>> >>>- >>>To unsubscribe, e-mail: [EMAIL PROTECTED] >>>For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> >> >>- >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] > > >_ >Add photos to your e-mail with MSN 8. Get 2 months FREE*. >http://join.msn.com/?page=features/featuredemail > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webpage & servlets !
hey filip ! ur right that my servlets should be inside classes, but my classes are under WEB-INF, and i guess thats what the documentation on the servlet says in the book ADVANCED JAVA PROGRAMMING - by Dietel & Dietel. Anyway i will be glad if u could explain to me after seeing my directory stucture, as to where should i move my files for running the servlets. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: "Filip Hanik" <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Subject: RE: webpage & servlets ! Date: Mon, 17 Feb 2003 10:23:34 -0800 your servlet should also be under classes, not under WEB-INF Filip ~ Namaste - I bow to the divine in you ~ Filip Hanik Software Architect www.filip.net >-Original Message- >From: Swapneel Dange [mailto:[EMAIL PROTECTED]] >Sent: Monday, February 17, 2003 10:12 AM >To: [EMAIL PROTECTED] >Subject: Re: webpage & servlets ! > > >yeah, there is the servlet code as an attachment to this mail. and ther >hierarchy for the servlet classes are as folllows : > >webapps > ROOT > dange > frame0.txt > frame0.html > frame1.html > WEB-INF > classes > ranade > SubmitServlet.java > SubmitServlet.class and all other supporting class files. > >i am not able to understand the meaning of the error such as the >following : > >java.io.FileNotFoundException: >C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\ >dange\frame0.html >(The system cannot find the path specified) > >although it says that FILE NOT FOUND, but i am pretty sure that >the FILE is >there in the directory, anyways.. ! > >Swapneel Dange >505-642-4126 >http://www.cs.nmsu.edu/~sdange > > > > > > > > > > > >>From: Peng Tuck Kwok <[EMAIL PROTECTED]> >>Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >>To: Tomcat Users List <[EMAIL PROTECTED]> >>Subject: Re: webpage & servlets ! >>Date: Mon, 17 Feb 2003 15:55:58 +0800 >> >>I do not see why you cannot access a directory under a legit webapp, much >>less get the text file you put in there. >> Can you please send your servlet code ? >> >>Swapneel Dange wrote: >>>i am accesing the webpage inside the SERVLET itself. and i am trying to >> >>>access them as normal webpage and normal .txt page, but the .txt page is >>>then made into a .html page. >>> >>>And there is no link as such on nay page for the webpage i am trying to >>>access. i am accessing them through the html tags inside the servlet >>>itself. >>> >>> >>>Swapneel Dange >>>505-642-4126 >>>http://www.cs.nmsu.edu/~sdange >>> >>> >>> >>> >>> >>>>From: Peng Tuck Kwok <[EMAIL PROTECTED]> >>>>Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >>>>To: Tomcat Users List <[EMAIL PROTECTED]> >>>>Subject: Re: webpage & servlets ! >>>>Date: Mon, 17 Feb 2003 14:30:07 +0800 >>>> >>>>How are you referring to the link in your html or jsp page? >>>> >>>>Swapneel Dange wrote: >>>> >>>>>hi there ! >>>>> >>>>>i am running a servlet, which takes the username and then the password >>>>>and opens another webpage in the browser , my servlet is under the >>>>>webapps/ROOT/WEB-INF/classes but my .txt file for running the webpage >>>>>are not inside the directory known as classes( i am generating >a webpage >>>>>by making a .txt file first and then making a .html file out of that) >>>>> >>>>>the .txt and .html files are under webapps/ROOT/dange/ , and >whenever i >>>>>try to access the .txt files, i get some error like tha one i >am sending >>>>>here. >>>>> >>>>>can anybody help me on this ! >>>>> >>>>> >>>>>java.io.FileNotFoundException: >>>>>C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\R >OOT\dange\frame0.html >>>>>(The system cannot find the path specified) >>>>> >>>>> >>>>> >>>>>Swapneel Dange >>>>>505-642-4126 >>>>>http://www.cs.nmsu.edu/~sdange >>>>> >>>>> >>>>> >>>>> >>>>>
RE: webpage & servlets !
john ! i think that the first thing u referred to the fact that i am generating a .txt and .html file , which eventually gets fed to the browser to view the webpage i want. Exactly thats what i am trying to do but i think that i have somewhere in keeping the proper directory stucture. And thats why i was curious to know has anybody ever had this problem wherein it was solved or not ? Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: "Turner, John" <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: 'Tomcat Users List' <[EMAIL PROTECTED]> Subject: RE: webpage & servlets ! Date: Mon, 17 Feb 2003 08:31:08 -0500 I think you've got your terminology a little mixed up. "Accessing them through the HTML tags inside the servlet itself" isn't possible. If you mean that your servlet generates HTML text that is sent to the browser, and some of that HTML text refers to the page you are looking for, then the URL needs to be a URL that the client browser can resolve, that is something like http://www.host.com/myWebApp/somepage.html. If you mean that your servlet is trying to read the file that is sitting on your hard drive, using some sort of Java File object, then you need to refer to the file in a filesystem-related manner, such as "myWebApp/somepage.html". In either case, you will get much faster (and more accurate) help if you: 1) explain exactly what it is you want to do, and 2) post the code that you've written that is trying to do it, and 3) describe the manner (URL) you're using to execute that servlet code, and 4) post the error message you get when you execute that code John > -Original Message- > From: Swapneel Dange [mailto:[EMAIL PROTECTED]] > Sent: Monday, February 17, 2003 2:32 AM > To: [EMAIL PROTECTED] > Subject: Re: webpage & servlets ! > > > i am accesing the webpage inside the SERVLET itself. and i am > trying to > access them as normal webpage and normal .txt page, but the > .txt page is > then made into a .html page. > > And there is no link as such on nay page for the webpage i am > trying to > access. i am accessing them through the html tags inside the > servlet itself. > > > Swapneel Dange > 505-642-4126 > http://www.cs.nmsu.edu/~sdange > > > > > > >From: Peng Tuck Kwok <[EMAIL PROTECTED]> > >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> > >To: Tomcat Users List <[EMAIL PROTECTED]> > >Subject: Re: webpage & servlets ! > >Date: Mon, 17 Feb 2003 14:30:07 +0800 > > > >How are you referring to the link in your html or jsp page? > > > >Swapneel Dange wrote: > >>hi there ! > >> > >>i am running a servlet, which takes the username and then > the password and > >>opens another webpage in the browser , my servlet is under the > >>webapps/ROOT/WEB-INF/classes but my .txt file for running > the webpage are > >>not inside the directory known as classes( i am generating > a webpage by > >>making a .txt file first and then making a .html file out of that) > >> > >>the .txt and .html files are under webapps/ROOT/dange/ , > and whenever i > >>try to access the .txt files, i get some error like tha one > i am sending > >>here. > >> > >>can anybody help me on this ! > >> > >> > >>java.io.FileNotFoundException: > >>C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapp > s\ROOT\dange\frame0.html > >>(The system cannot find the path specified) > >> > >> > >> > >>Swapneel Dange > >>505-642-4126 > >>http://www.cs.nmsu.edu/~sdange > >> > >> > >> > >> > >>_ > >>Help STOP SPAM with the new MSN 8 and get 2 months FREE* > >>http://join.msn.com/?page=features/junkmail > >> > >> > >> > - > >>To unsubscribe, e-mail: [EMAIL PROTECTED] > >>For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > > >- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > _ > Add photos to your e-mail with MSN 8. Get 2 months FREE*. > http://join.msn.com/?page=features/featuredemail > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webpage & servlets !
> i think that the first thing u referred to the fact that i am generating a > .txt and .html file , which eventually gets fed to the browser to view the > webpage i want. Exactly thats what i am trying to do but i think that i > have somewhere in keeping the proper directory stucture. Do you mean that inside your Servlet, you're using some sort of Writer and generating text that gets saved to a file? I can't imagine why you'd want to do this, but if you insist, then try a relative path using '..' to back up one level and write the file. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management
RE: webpage & servlets !
Wendy ! i am creating a webpage using the HTML ags inside the servlets, and why i am using the .txt file becuase i find its easy to update my webpage using the .txt file whenever needed. but if i use straight away the HTML tags inside the servlet to access in the BROWSER the relevant webpage then everytime to make a small change i will have to change the HTML tags inside the servlet. Using a .txt file solves this problem that everytime i wont have to tamper my servlet code for any relevant changes in the WEBPAGE. i can just make the changes in the .txt and they will be reflected in the WEBAPGE. but the problem i am having now is, i am not able to access the .html or the .txt file which is created by the servlet itself. as the servlet is not able to locate the file it creates by itself. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Wendy Smoak <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: 'Tomcat Users List' <[EMAIL PROTECTED]> Subject: RE: webpage & servlets ! Date: Mon, 17 Feb 2003 13:05:47 -0700 > i think that the first thing u referred to the fact that i am generating a > .txt and .html file , which eventually gets fed to the browser to view the > webpage i want. Exactly thats what i am trying to do but i think that i > have somewhere in keeping the proper directory stucture. Do you mean that inside your Servlet, you're using some sort of Writer and generating text that gets saved to a file? I can't imagine why you'd want to do this, but if you insist, then try a relative path using '..' to back up one level and write the file. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management _ STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
In line 148 of your source code (I assume you haven't change or added anything to servlet) you write : output.write ("http://128.123.130.247:8080/webapps/ROOT/dange/frame0.html\";>"); Try changing it to : output.write ("http://128.123.130.247:8080/dange/frame0.html\";>"); As Wendy suggested you might want to look at changing your urls to use relative paths. Swapneel Dange wrote: Wendy ! i am creating a webpage using the HTML ags inside the servlets, and why i am using the .txt file becuase i find its easy to update my webpage using the .txt file whenever needed. but if i use straight away the HTML tags inside the servlet to access in the BROWSER the relevant webpage then everytime to make a small change i will have to change the HTML tags inside the servlet. Using a .txt file solves this problem that everytime i wont have to tamper my servlet code for any relevant changes in the WEBPAGE. i can just make the changes in the .txt and they will be reflected in the WEBAPGE. but the problem i am having now is, i am not able to access the .html or the .txt file which is created by the servlet itself. as the servlet is not able to locate the file it creates by itself. Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Wendy Smoak <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: 'Tomcat Users List' <[EMAIL PROTECTED]> Subject: RE: webpage & servlets ! Date: Mon, 17 Feb 2003 13:05:47 -0700 > i think that the first thing u referred to the fact that i am generating a > .txt and .html file , which eventually gets fed to the browser to view the > webpage i want. Exactly thats what i am trying to do but i think that i > have somewhere in keeping the proper directory stucture. Do you mean that inside your Servlet, you're using some sort of Writer and generating text that gets saved to a file? I can't imagine why you'd want to do this, but if you insist, then try a relative path using '..' to back up one level and write the file. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management _ STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
Hi Swapneel ! I'm pretty sure there's a typo there, because the error is pretty specific, and in my experience, it definitely points to either a non-existent file, directory, or a typo. Can you confirm if your directory structure is as shown below : C:\ tomcat jakarta-tomcat-3.1.1a jakarta-tomcat-3.1.1a<--- is there an error here ? webapps ROOT dange java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
hey CHONG ! there is no TYPO there in the naming of the directory as i have created that complx structure of directories by mistake, but they are realy all right ! there is something about not locating the FILE, i think ! but i am not sure ! Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Chong Yu Meng <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Tue, 18 Feb 2003 09:40:56 +0800 Hi Swapneel ! I'm pretty sure there's a typo there, because the error is pretty specific, and in my experience, it definitely points to either a non-existent file, directory, or a typo. Can you confirm if your directory structure is as shown below : C:\ tomcat jakarta-tomcat-3.1.1a jakarta-tomcat-3.1.1a<--- is there an error here ? webapps ROOT dange java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: webpage & servlets !
hey WENDY, JOHN , CHONG, PENG ! all those who were trying to help me, i am SORRY guys, there was a mistake on my part in writing the name of the FOLDER wrong in the path, i specified. anyway i really thank all of u for helping me in finding the error. i hope that i wil bore u with some more interesting errors in future :)) Swapneel Dange 505-642-4126 http://www.cs.nmsu.edu/~sdange From: Chong Yu Meng <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: webpage & servlets ! Date: Tue, 18 Feb 2003 09:40:56 +0800 Hi Swapneel ! I'm pretty sure there's a typo there, because the error is pretty specific, and in my experience, it definitely points to either a non-existent file, directory, or a typo. Can you confirm if your directory structure is as shown below : C:\ tomcat jakarta-tomcat-3.1.1a jakarta-tomcat-3.1.1a<--- is there an error here ? webapps ROOT dange java.io.FileNotFoundException: C:\tomcat\jakarta-tomcat-3.1.1a\jakarta-tomcat-3.1.1a\webapps\ROOT\dange\frame0.html (The system cannot find the path specified) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ The new MSN 8: advanced junk mail protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]