You can use JSTL to accomplish this using the: <c:set var="username" value="${username}" />
You can also specify the scope within the value expression. This is if you wish to use JSTL. Only a suggestion. Hope it helps you out! --- struts <[EMAIL PROTECTED]> wrote: > In the Jsp i have: > > <sess:attribute name="userName"/> > > witch prints the username. Now i want something like: > > <% > > String username= <sess:attribute name="userName"/>; > > %> > > but that doesn't work. How can i assign the session variable to the > String username ? > > Thanks ! > > > ===== Oron Gill Haus IBM CSE Content Manager 8 - Sun Certified Programmer Java 2 1.4 office: (410) 539-3733 x1348 fax: (410) 837-9535 c/o Oron e-mail: [EMAIL PROTECTED] web: http://www.electronicscene.com/oron_haus --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]