模仿asp.net的checkboxList控件

goldlive_8888 2009-06-09 11:02:09
<script type="text/javascript">
function rowIn(obj){
obj.style.backgroundColor="#316AC5";
obj.style.color="#FFFFFF";
}
function rowOut(obj){
obj.style.backgroundColor="#FFFFFF";
obj.style.color="#000000";
}
function rowCheck(obj){
obj.firstChild.firstChild.checked=!obj.firstChild.firstChild.checked;
}
</script>
<select multiple>
<option>1</option>
<option>2</option>
</select>
<div style="width:200px;height:200px;border:1px solid #7F9DB9">
<div style="margin:1px;width:195px;height:195px;overflow:auto;border-top:1px solid #716F64;border-left:1px solid #716F64;border-right:1px solid #F1EFE2;border-bottom:1px solid #F1EFE2">
<table style="width:100%">
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="1">计划A</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="2">计划B</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="3">计划C</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="4">计划D</td>
</tr>
</table>
</div>
</div>
希望能帮助从事java Web开发兄弟姐妹们!
...全文
145 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
goldlive_8888 2009-06-16
  • 打赏
  • 举报
回复
<script type="text/javascript">
function rowIn(obj){
obj.style.backgroundColor="#316AC5";
obj.style.color="#FFFFFF";
}
function rowOut(obj){
obj.style.backgroundColor="#FFFFFF";
obj.style.color="#000000";
}
function rowCheck(obj){
obj.firstChild.firstChild.checked=!obj.firstChild.firstChild.checked;
}
</script>
<select multiple>
<option>1</option>
<option>2</option>
</select>
<div style="width:200px;height:200px;border:1px solid #7F9DB9">
<div style="margin:1px;width:195px;height:195px;overflow:auto;border-top:1px solid #716F64;border-left:1px solid #716F64;border-right:1px solid #F1EFE2;border-bottom:1px solid #F1EFE2">
<table style="width:100%">
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="1" onclick="this.checked=!this.checked">计划A</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="2" onclick="this.checked=!this.checked">计划B</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="3" onclick="this.checked=!this.checked">计划C</td>
</tr>
<tr onmouseover="rowIn(this)" onmouseout="rowOut(this)" onclick="rowCheck(this)">
<td><input type="checkbox" value="4" onclick="this.checked=!this.checked">计划D</td>
</tr>
</table>
</div>
</div>
浪尖赏花 2009-06-09
  • 打赏
  • 举报
回复
支持一哈
源码链接: https://pan.quark.cn/s/a4b39357ea24 在本研究中,我们将详细研究如何借助Python执行数据可视化,旨在剖析2018年期间中国四个主要城市——北京、上海、广州以及深圳的空气质量状况。通过绘制反映空气质量指数(AQI)与细颗粒物(PM2.5)变化趋势的图表,我们能够深入理解这些大都市全年的空气环境质量,并明确评估其优良天气所占的比重。 我们必须首先进行数据准备工作。在当前提供的压缩文件内,名为"2018天气"的文件极有可能是数据来源,其中可能收录了涉及四个城市每日空气质量监测的详细信息。这些数据通常涵盖日期、城市名称、AQI数值、PM2.5含量等核心参数。在Python编程环境中,我们惯常运用pandas库来对这类结构化数据进行高效的处理和分析。 1. **数据导入与初步处理**: - 利用`pandas.read_csv()`方法来导入存储为CSV格式的数据资料。 - 数据整理:对数据中的空白项、非正常数值进行修正,保证数据的精确性。 - 调整日期字段的格式,确保其能够适用于时间序列分析的需求。 2. **数据深度分析**: - 针对每个城市的AQI和PM2.5数据执行统计性描述,例如计算平均值、中位数、标准偏差等指标。 - 确定空气质量良好天气的天数,即那些AQI值低于75(依据中国的空气质量评估标准)的日数。 3. **数据呈现**: - 运用matplotlib或seaborn工具绘制折线图,直观展示四个城市在2018年全年的AQI和PM2.5变化动态。 - 可通过采用不同的颜色方案和线条类型来区分不同城市的数据系列。 - 添加必要的图示元素,如日期坐标轴、城市名称标注、图表标题及图例说明,以提升图表的可读...

87,988

社区成员

发帖
与我相关
我的任务
社区描述
Web 开发 JavaScript
社区管理员
  • JavaScript
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧