Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem of <frameset> tag with struts2

 
Prajatna Mahunta
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am migrating my application from struts 1 to staruts 2

We are using struts 2.1.8 jar. We were using <fameset> to have our website layout.

But unfortunately using <fameset> the struts 2 is not able to render the page. In the UI it is only showing "undefined" . Please suggest how to make <frameset > work in struts2
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You've provided almost no information we can use to help you.

Please read ItDoesntWorkIsUseless and TellTheDetails.
 
Prajatna Mahunta
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
From 1st jsp page I am calling a action "login.action"

The struts.xml mapping is like-


Inside zulaHome.jsp I am using <frameset> tag to create the Welcome page which is a combination of header, menu & body .
The code I am using for zulaHome.jsp is as follows



I can see in my console that on call of this login.action my zulaHome.jsp page is loading. But in UI i am not able to see any thing . only it is showing a single word "undefined".

As you can see I have tried various option for the <frame src="" > tag as follows.

(1. using jsp location,


2. using s:url tag to load the jsp ,


3. using a action to load the corresponding JSP


)
But non of these worked out for me..

Can you please let me know id these is any comparability issue is there with struts2 & <frameset> tag ?
If not why this is happening..and what is the solution for this. ???

can any body please help me.
 
Anbarasu Aladiyan
Ranch Hand
Posts: 182
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Prajatna Mahunta,

I have used the same thing in my last project with out any problem.
like below (this code is a part of the page which will be displayed after successful login validation)


All the src attribute calls a struts2 action. But i have not build the url using strut2 url tag.
It worked well for me...
 
Prajatna Mahunta
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
anbarasu aladiyan wrote:Hi Prajatna Mahunta,

I have used the same thing in my last project with out any problem.
like below (this code is a part of the page which will be displayed after successful login validation)
zulaHome.jsp


All the src attribute calls a struts2 action. But i have not build the url using strut2 url tag.
It worked well for me...



Thanks Anbarasu ,
I tried with your solution. But still I am facing the same problem..Is there any problem with Struts version, I am using Struts 2.1.8

I have changed the frameset page like--


And the corresponding action mapping is--


And the action class is --



I am still wondering ...why i am not able to get my page , because i can see in the logs that my frameset page() is getting called




But in UI still it is coming "undefined" .

Can anybody please help me out..
 
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 you mean by " In the UI it is only showing "undefined"". You don't show the JSP, so we can't help diagnose a JSP problem.

Struts 2 has absolutely nothing to do with framesets. Do your actions work on their own, i.e. if you just call them manually? Are you using JavaScript in the pages?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic