日期:2014-05-16 浏览次数:20326 次
<table width="100%" border="0"> <tr> <td>-asd</td> <td>-asdf</td> <td>sadf</td> <td>asdf</td> <td>2112</td> </tr> <tr> <td>121</td> <td>123</td> <td>-1312</td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> </table> <script> mytd = document.getElementsByTagName("td") alert(mytd); for(key=0;key<mytd.length;key++){ v = mytd[key].innerText; if(/\-/.test(v)) mytd[key].style.color="green" else m