This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How To Use Servlet Instead Of Jsp In Struts2

 
Thangaraj Selvamani
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hai Iam New To Struts2. Can Any One Say Me How To Use Servlet Instead Of Jsp Page.

Thanks In Advance
Thangaraj
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Servlets instead of JSP ? Why ? This would break the whole purpose of using Struts.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why do you think you want to do this? Heck, that wouldn't just defeat the purpose of using Struts, it'd defeat the purpose of everything invented at the time JSP came out.
 
Thangaraj Selvamani
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Customized Jsp Component Wants To Get Create(With textfield, select, button etc... ) At RunTime.And Gets Loaded For The End User.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not sure what that has to do with servlets, though--generating HTML with a servlet is just yucky, and there are better alternatives.

(On a side note, there's no reason to capitalize every word in a sentence--that's only for things like the titles of books :)
 
Thangaraj Selvamani
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can you give some sollutions how to generate struts2 jsp component at run time and load the page to user.

thanks in advance
s.thangaraj
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSP? But remember: the ultimate goal isn't to create S2 JSP components, but rather to generate the appropriate HTML. Right now it sounds as though you want to create actual JSP, *then* interpret it so tags are rendered, and serve *that* to the user.

Without more details is tough to help, though.
 
Thangaraj Selvamani
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My requirement: I am developing web application which can be acessible by A and B users.
In my application I am having only one jsp page. This jsp page can be used by more than
one user that too more than one functionality.
A is using X functionality.B is using Y functionality.
To satisfy these users A and B , I need to display the required jsp/html view controls.
These jsp view controls are comes from database.The view controls in jsp page are
equivalent to the fields/columns in database table.
Now I need to dynamically change/show the view controls in the only available jsp page.
Please give me a solution....
Thanks in Advance.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So far it still just sounds like you need to show specific information to a specific user, and there's nothing here that can't be handled in a clean way. Still not information given to provide any specifics, however. And so far it's not Struts-specific.
 
sarada srinivas
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since you have only one jsp page, Please use <s:if></s:if> tag and make use as per user request.

-Sarada.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic