[原创]table动态改变颜色包括一个边框

<script type="text/javascript"> function StorePage() { d=document; t=d.selection?(d.selection.type!='None'?d.selection.createRange().text:''):(d.getSelection?d.getSelection():''); void(keyit=window.open('http://www.365key.com/storeit.aspx?t='+escape(d.title)+'&u='+escape(d.location.href)+'&c='+escape(t),'keyit','scrollbars=no,width=475,height=575,left=75,top=20,status=no,resizable=yes')); keyit.focus(); } </script> 

#region 声明
//----------------------------------------------------------------------
//
// 作者: 李淼(Nick.Lee)
//
// table动态改变颜色包括一个边框

// 时间:2005-3-1,我做了两天的效果哦

// boyorgril@msn.com
// QQ:16503096
//注意:引用请标明出处,如果觉得好请up一下或评论一下,谢谢
//----------------------------------------------------------------------
#endregion

<HTML>
<HEAD>
<title>table动态改变颜色包括一个边框</title>
</HEAD>

<form name="Form1" method="post" action="topmenu_main.aspx" id="Form1">

<table style="width: 100%;font-size:9pt;" border=0 cellpadding="0" cellspacing="0" id="datagrid1"><tr><td>

<table style="border: SOLID 1px blue;border-top: -1px;  width: 100%;" cellpadding="0" cellspacing="0">
<tr>
 <td>
  <table width=100% heigh=100% cellpadding="4" cellspacing="1" style="font-size:9pt;">
  <tr bgcolor="#8888BB" align="center" style="color:white;">
   <td style="width:20%;">&nbsp;</td>
          <td style="width:20%;">&nbsp;</td>
          <td style="width:20%;">编号</td>
          <td style="width:20%;">中文名称</td>
          <td style="width:20%;">图片Url</td>
  </tr>
  </table>
 </td>
</tr>
</table>

<table style="border: SOLID 1px blue; border-top: 0px; width: 100%" cellpadding="0" cellspacing="0"
    OnMouseOver="this.style.border='SOLID 1px BLACK'; this.style.marginTop=-1"
    OnMouseOut ="this.style.border='SOLID 1px blue'; this.style.marginTop=0; this.style.borderTop='0px'">
<tr>
 <td>
  <table width=100% heigh=100% cellpadding="4" cellspacing="1" style="font-size:9pt;">
  <tr align="center" bgcolor="#EEEEFA" onMouseOut="this.style.backgroundColor='#EEEEFA';this.style.cursor='hand';" onmouseOver="this.style.backgroundColor='#C0C0FF'">
       <td style="width:20%;color:red;">添加</td>
          <td style="width:20%;color:red;">删除</td>
          <td style="width:20%;">00001</td>
          <td style="width:20%;">Nick</td>
          <td style="width:20%;">图片1</td>
  </tr>
  </table>
 </td>
</tr>
</table>

<table style="border: SOLID 1px blue; border-top: 0px; width: 100%" cellpadding="0" cellspacing="0"
    OnMouseOver="this.style.border='SOLID 1px BLACK'; this.style.marginTop=-1"
    OnMouseOut ="this.style.border='SOLID 1px blue'; this.style.marginTop=0; this.style.borderTop='0px'">
<tr>
 <td>
  <table width=100% heigh=100% cellpadding="4" cellspacing="1" style="font-size:9pt;">
  <tr align="center" bgcolor="#EEEEFA" onMouseOut="this.style.backgroundColor='#EEEEFA';this.style.cursor='hand';" onmouseOver="this.style.backgroundColor='#C0C0FF'">
       <td style="width:20%;color:red;">添加</td>
          <td style="width:20%;color:red;">删除</td>
          <td style="width:20%;">00002</td>
          <td style="width:20%;">Rick</td>
          <td style="width:20%;">图片2</td>
  </tr>
  </table>
 </td>
</tr>
</table>
</td></tr></table>
  
</form>
</HTML>



  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值