Im using JSF time ago, and i see that the concept of MODEL is really important there. Here, on struts2, i see that this concept is a bit obsolete. For example, seems that is impossible to set a Bean session scoped; instead i need to put the whole Bean (object) into the session (manually).
So, in some methods, this is not nice. For example, for the page-switch, i have implemented (on JSP page) this :
<s:div cssClass="content" id="content">
<%
String pageValue=request.getParameter("page");
if((pageValue!=null) && (pageValue.compareTo("articles")==0)) {
%>
<s:include value="articles/articles.jsp"></s:include>
<%
} else {
%>
<s:include value="homepage/homepage.jsp"></s:include>
<%
}
%>
</s:div>
is this the right way to work with Struts2? Or is better put some values into Beans and generate the page accordings to the Beans values? (Model concept, but REALLY i don't know hot to set the Bean scope, and i wont put them on session. Else is like do procedual coding, and i can use PHP to do this :)).
I Don't know how to do it otherwise :)
Cheers