图形图像 多媒体类 机械电子 办公系列 程序设计 网站开发 数据库教程 路由技术 网络原理 网络应用 考试认证
手机分类
  网站导航: 电脑时代在线 · 网站开发 · JSP教程 · JSP开发实例

jsp在线考试系统-jsp文件

手机资讯
『jsp在线考试系统-jsp文件』如果文章中有大量图片,显示会较慢,请等待图片下载完成
 
点击数: 来源:无 更新时间:2005-8-22 



一个在线考试系统,测试你的jsp知识,代码不是特别多,所以不加注释了(http://jspbbs.yeah.net)

answer.jsp

<%-- Include directive --%>
<%@ include file="header.html" %>

<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
<TR>
<TD VALIGN="TOP"><FONT FACE="Verdana, Arial, Helvetica, sans-serif">
<DIV ALIGN="RIGHT">
<FONT SIZE="-1"><A HREF="/developer/Quizzes/index.html">Quizzes
Index</A></FONT></DIV>
<H2 ALIGN="RIGHT"><FONT COLOR="#FFFFFFF">JSP Professional, Chapter 12 Quiz
Answers</FONT></H2>
<H4 ALIGN="RIGHT"><EM>by Dan Malks</EM></H4>
<BR><BR>
<TABLE BORDER="0" CELLSPACING="8" CELLPADDING="2" <TR><TD>
<FONT FACE="Verdana, Arial, Helvetica, sans-serif">

<%-- Page directive that applies to entire page. --%>
<%@ page language="java" %>

<%-- Identifies bean as "worker" and tells the page where to locate the bean. --%>
<jsp:useBean id="worker" class="jdc.quiz.QuizResponses" scope="request" />

<%-- Set bean properties with a wildcard. --%>
<jsp:setProperty name="worker" property="*" />

<%-- Scoring --%>

<%-- Variable declaration in code scriptlet -->
<% int score = 0; %>

<!-- Quiz Questions -->

<!-- Question 1 -->

<TR><TD VALIGN="TOP"><FONT FACE="Verdana, Arial, Helvetica, sans-serif">1.</FONT></TD>

<%-- The method getOne() was set up in the bean with the id "worker" --%>
<%-- All Java code is enclosed in <% %>, leaving HTML to be easily --%>
<%-- changed or updated. --%>

<% if((worker.getOne() != null) && ((worker.getOne()).equals("D"))) { score ++; %>

<TD VALIGN="TOP"><FONT FACE="Verdana, Arial, Helvetica, sans-serif"> <B>D</B>
is correct!</FONT></TD>

<% } else if (worker.getOne() != null) { %>

<TD VALIGN="TOP"><FONT COLOR=red><jsp:getProperty name="worker" property="one" />
is incorrect!</FONT></TD>

<% } else { %>

<TD VALIGN="TOP">Blank <FONT COLOR=red>X</FONT></TD>

<% } %>

<TD VALIGN="TOP"><FONT FACE="Verdana, Arial, Helvetica, sans-serif">
Every JavaServer Pages<SUP><FONT SIZE="-2">TM</FONT></SUP>
(JSP)<SUP><FONT SIZE="-2">TM</FONT></SUP>source page

[1] [2] [3] [4] [5] [6] [7] 下一页

】【关闭窗口
  上一页:
  下一页:
 ·网站导航: 电脑时代在线 · 网站开发 · JSP教程 · JSP开发实例
JSP开发实例:相关文章
JSP开发实例点击榜
普通教程一个可以防止刷新地JSP计数器
普通教程jsp文件操作之写入篇
普通教程jsp文件操作之追加篇
普通教程jsp文件操作之读取篇
普通教程jsp计数器制作手册
普通教程jsp计数器代码
普通教程jsp原始代码实际示例1(输出)
普通教程jsp原始代码实际示例2(获取表单
普通教程jsp原始代码实际示例3(获取jsp
普通教程jsp原始代码实际示例4(搜索引擎
搞笑自拍|图片故事|美女图库|体坛宝贝|明星爆料|世界奇观|风光摄影|历史回忆|大千世界
JSP开发实例推荐图片
advertisement
关于站点 - 广告服务 - 联系我们 - 版权隐私 - 免责声明 - 合作伙伴 - 程序支持 - 网站地图 - 返回顶部  
网站文本地图
  版权所有:电脑时代在线 2005-2009 欢迎各种媒体转载我们的原创作品[转载请注明出处]
copyright © 2005-2007 www.PCvz.com online services. all rights reserved. 蜀ICP备05015578
Template designed by PCX. Optimized for 1024x768 to Firefox,Opera and MS-IE. Site powered by EQL.
红盾
热爱电脑,热爱生活
拥有电脑,拥有生命
让我们享受拥有电脑的时光