• 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

Two actions in a single JSP

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

I ham having login and register in a single jsp page. i can't use two actions in single jsp page please help me to solve my issue. and the main thing is it wants to display in right side.


I have developed but my login text field only coming in right side my register field it's not coming in right side please help me.




My register field is coming in left on the login field please solve my issue. No one is not there to guide me in my office please solve me. within a day i wants to solve my issue. please help me.

If iam using single form with action it is coming in right side but i can't bring two actions in sing jsp page in right side.


Thanks in advance.
 
Sheriff
Posts: 17644
300
Mac Android IntelliJ IDE Eclipse IDE Spring Debian Java Ubuntu Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

P Arunkumar wrote:My register field is coming in left on the login field please solve my issue. No one is not there to guide me in my office please solve me. within a day i wants to solve my issue. please help me.


First of all: EaseUp (<-- click the link)

Table-based layouts are inefficient and outmoded; they're so 1990s. Please use CSS to style forms so that they are displayed where you want them on the page.
 
Ranch Hand
Posts: 859
IBM DB2 Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have some html errors in there, "<<s:" on line 15/16 ?

Also your second table has no <tr><td>

If you want the forms aligned horizontally, create a wrapper table with two cells.
(If you want to stay with tables, css and divs are the better more modern way)

<table>
<tr><td>LOGIN Stuff</td><td>REGISTER Stuff</td></tr>
</table>

WP
 
P Arunkumar
Ranch Hand
Posts: 119
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for reply.

I agree that we can use CSS instead of table format. but question is i wants to use two actions in single jsp page. please help me.
 
Ranch Hand
Posts: 329
Eclipse IDE Oracle Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Arun,
One way out is to have a javascript method for the second action and use this javascript method to set the action explicitly . something like
 
P Arunkumar
Ranch Hand
Posts: 119
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Thank You So Much.... I have completed my task. Its working perfectly. 2 forms 2 actions in a single page. I have used Servlet concept on this, but for time being i have completed in servlet but after completing in will post my code in struts.


Main.jsp



Login.java




Register.java



 
permaculture is giving a gift to your future self. After reading this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic