• Post Reply Bookmark Topic Watch Topic
  • New Topic

Connect to diff pages

 
sumaraghavi ragha
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hai All,

I had diff htmls like login,welcom and error

I want to connect from one another by using a servlet how can i do that

Help me out

Suma
 
Srikkanth Mohanasundaram
Ranch Hand
Posts: 243
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hai All,

I had diff htmls like login,welcom and error

I want to connect from one another by using a servlet how can i do that

Help me out

Suma


You need to have a web.xml file in your application.A sample web.xml would look like this:
<web-app>
<welcome-file-list>
<welcome-file>login</welcome-file>
</welcome-file-list>
<servlet>
<servlet-name>Your Servlet</servlet-name>
<servlet-class>com.something.YourClass</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Your Servlet</servlet-name>
<url-pattern>/welcome.do</url-pattern>
</servlet-mapping>

Add your business logic in a Java Class and forward the results from the servlet to the error.jsp or the result.jsp as you wish.

Thanks,
Srikkanth.M
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65519
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"diff" is not a word. Please use real words when posting to the forums. Please read this for more information.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!