挑战:
将点击事件分配给将在容器内绘制标记的东西.计数标记应该与已经绘制的其他计数标记相对应,因此计数标记的定位是有意义的.每次点击后,计数标记应代表到目前为止的总点击次数.
这些是理货标记:
1 2 3 4 5
? ? ? ? ?
Run Code Online (Sandbox Code Playgroud)

以下示例的计数标记计数为83:

挑战规则:
我有使用html元素的按钮的sitewiode样式.对于提交表单的按钮,这很有效.但是有些按钮只是链接.因此我使用这种语法:
<a href="#"><button>Link Text</button></a>
Run Code Online (Sandbox Code Playgroud)
这适用于除IE以外的所有浏览器,其中按钮单击但没有任何反应.链接未被遵循.
我怎样才能在IE中使用它?
只是我或任何JavaScript DOM操作或WEB UI框架代码真的很难掌握,因为文件很长,缺少适当的缩进和评论的稀缺性?
我已经阅读了几本关于JavaScript的好书并且喜欢这种语言,但是当我试图理解所有流行框架的内部工作时,我很难强迫自己超越一百个大文件的行.
这是一个真实的问题,而不是一个陈述.我只是想了解我是否只是吮吸或其他人分享我的印象.
我希望"app1"向左移动并同时淡出?
功能正逐一执行.我希望它同时发生.我不希望它向左移动然后淡出.
谢谢!
<!DOCTYPE html>
<html>
<head>
<title>Forget Me Not</title>
<style>
body
{
background-color:#66d9ff;
}
#app1{
position:absolute;
width:250px;
height:250px;
z-index:0;
top:50%;
left:50%;
margin:-150px 0 0 -150px;
background:white;
box-shadow: 0 0 1px 1px #888888;
text-align:center
}
img.appIMG1{
-webkit-box-shadow: 0 0 1px 1px #888888;
box-shadow:0 0 1px 1px #888888;
}
img.appIMG2{
-webkit-box-shadow: 0 0 1px 1px #888888;
box-shadow:0 0 1px 1px #888888;
}
</style>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script>
$(document).ready(function () {
$(".appIMG1").click(function () {
$("#app1").animate({
left: '250px'
});
$("#app1").fadeOut();
});
});
</script>
</head> …Run Code Online (Sandbox Code Playgroud) 看下面的代码:
<?php
$output += "
<table border='1'>
<tr>
<th>Session ID</th>
<th>TeacherUsername</th>
<th>Teacher Name</th>
<th>Module Number</th>
<th>Module Name</th>
<th>Course ID</th>
<th>Course Name</th>
<th>Year</th>
<th>Student Username</th>
<th>Student Name</th>
<th>Mark</th>
<th>Grade</th>
</tr>
";
$total = 0;
$count = 0;
while ($row = mysql_fetch_array($result)) {
$count++;
$total += $row['Mark'];
$output += "
<tr>
<td>{$row['SessionId']}</td>
<td>{$row['TeacherUsername']}</td>
<td>{$row['TeacherForename']} {$row['TeacherSurname']}</td>
<td>{$row['ModuleId']}</td>
<td>{$row['ModuleName']}</td>
<td>{$row['CourseId']}</td>
<td>{$row['CourseName']}</td>
<td>{$row['Year']}</td>
<td>{$row['StudentUsername']}</td>
<td>{$row['StudentForename']} {$row['StudentSurname']}</td>
<td>{$row['Mark']}</td>
<td>{$row['Grade']}</td>
</tr>";
}
$output += " </table>";
$average = (int)($total/$count);
echo "<p>Average Mark: $average</p>";
echo $output;
?>
Run Code Online (Sandbox Code Playgroud)
由于某些奇怪的原因,它没有 …