题目内容

给定程序片断:<% String value = "beanvalue"; %><% request.setAttribute("com.example.been",value); %><%--插入代码处--%>在第3行插入EL表达式( ),能够计算并输出"beanvalue"。

A. ${ value }
B. ${ com.example.been beanvalue }
C. ${ requestScope["com.example.been"] }
D. ${request.getAttribute("com.example.been").toString()}

查看答案
更多问题

假定在web应用中,请求参数productID包含产品的标识符,下面EL表达式( )能够计算productID的值。

A. ${productID}
B. ${param.productID}
C. ${params.productID}
D. ${params.productID[1]}

JSP页面运行时被JSP引擎转化为( )。

A. HTML文件
B. CGI文件
CSS文件
D. Servlet文件

设置session的有效时间(也叫超时时间)的方法是( )。

A. setMaxInactiveInterval(int interval)
B. getAttributeName()
C. setAttributeName(String name, java.lang.Object value)
D. getLastAccessedTime()

Statement提供3个执行SQL语句的方法,其中用来执行更新操作的是( )。

A. excuteQuery()
B. executeUpdate()
C. next()
D. query()

答案查题题库