Ok I just started to learn JSP but I haven't found a little question I have in my book so here it is
I want to define a set of links that when clicked, will reload the current page the user is into, but with a different text according to the page you are into.
So say, I define a String setText(int text) function that will contain all the possible texts. However, how can I make that my link executes the session.setAttribute( "attribute",setText(numberhere)); thingy before reloading the page
Im guessing the page goes like this
<HTML>
<BODY>
<%= session.getAttribute( "attribute" ) %>
</BODY>
</HTML>
Also, how can I set that this "attibute" will be set to some welcome string by default (for the first time I load my page)
Or if my approach is plainly wrong please tell me how to do it
