当前位置: 代码迷 >> JavaScript >> 怎么通过脚本取table的值,多谢大家帮忙
  详细解决方案

怎么通过脚本取table的值,多谢大家帮忙

热度:31   发布时间:2012-02-20 21:18:25.0
如何通过脚本取table的值,谢谢大家帮忙
希望通过脚本循环以下table,得到结果

主要是要取每一行的值,没有值就不取了,xs3   有12,s3有2
"7"   Short   Zipper     xs3/12   s3/2 "
"3/4   Invisible   Zipper     xs3/12   s3/2 "
"Full   Concealed   Zipper     xs3/12   s3/2 "

<table   width= "777 "   border= "0 "   id= "3 ">
    <tr>
        <td> &nbsp; </td>
        <td> <font   face= "Verdana "   size= "1 "> XS   Qty </font> </td>
        <td> <font   face= "Verdana "   size= "1 "> Small   Qty </font> </td>
        <td> <font   face= "Verdana "   size= "1 "> Med   Qty </font> </td>
        <td> <font   face= "Verdana "   size= "1 "> Large   Qty </font> </td>
    </tr>
    <tr>
        <td> 7&quot;   Short   Zipper   </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "xs3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "s3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "m3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "l3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
    </tr>
    <tr>
        <td> 3/4   Invisible   Zipper </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "xs3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
        <td> <font   face= "Verdana "   size= "1 ">
            <input   size= "3 "   name= "s3 "   onChange= "total(3) "   readonly= " "   />
        </font> </td>
        <td> <font   face= "Verdana "   size= "1 ">
  相关解决方案