A.<%! int i; %> B.<%= int i; %> C.<jsp:expr>int i;</jsp:expr> D.<jsp:scriptlet>int i;</jsp:scriptlet> E.<jsp:declaration>int i;</jsp:declaration>
多项选择题Inwhichthreedirectories,relativetoawebapplication’sroot,mayataglibrarydescriptorfileresidewhendeployeddirectlyintoawebapplication?()
A./WEB-INF B./META-INF C./WEB-INF/tlds D./META-INF/tlds E./WEB-INF/resources F./META-INF/resources
多项选择题Giventhatascopedattributecartexistsonlyinauser’ssession,whichtwo,takenindependently,ensurethescopedattributecartnolongerexists?()
A.${cart = null} B.<c:remove var="cart" /> C.<c:remove var="${cart}" /> D.<c:remove var="cart" scope="session" /> E.<c:remove scope="session">cart</c:remove>
多项选择题Given in a single JSP page: <%@ taglib prefix=’java’ uri=’myTags’ %> <%@ taglib prefix=’JAVA’ uri=’moreTags’ %> Which two are true?()
A.The prefix ’java’ is reserved. B.The URI ’myTags’ must be properly mapped to a TLD file by the web container. C.A translation error occurs because the prefix is considered identical by the web container. D.For the tag usage , the tag1 must be unique in the union of tag names in ’myTags’ and’moreTags’.
单项选择题Whichinterfacemustasessionattributeimplementifitneedstobenotifiedwhenawebcontainerpersistsasession?()
A.javax.servlet.http.HttpSessionListener B.javax.servlet.http.HttpSessionBindingListener C.javax.servlet.http.HttpSessionAttributeListener D.javax.servlet.http.HttpSessionActivationListener
单项选择题A web application uses the HttpSession mechanism to determine if a user is logged in. When a usersupplies a valid user name and password, an HttpSession is created for that user. The user has access tothe application for only 15 minutes after logging in. The code must determine how long the user has beenlogged in, and if this time is greater than 15 minutes, must destroy the HttpSession. Which method in HttpSession is used to accomplish this?()
A.Getcreationtime B.Invalidateafter C.Getlastaccessedtime D.Getmaxinactiveinterval