简体   繁体   中英

Is it possible to use EL for sessionScoped bean without creating a new session in jsp

Basically, I want a jsp page that is only accessible to clients that have an existing session and do not create a new session for those who access the page directly with <%@ page session="false">. The existing session will have a bean set as a session attribute and I want to access this beans properties with EL.

The approach <%@ page session="false"> is wrong. Instead, I should let a jsp session be created and check with session.isNew and redirect those who access the page directly.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM