如何实现
点击一个浏览文件后,再出现另一个浏览文件。
<INPUT   id="up_file"    type="file"   size="19"   name="up_file"> 就是动态增加浏览控件。如果第一个控件里面有路径,第2个就显示。
如果第2个浏览里面没有内容,那就就剩下第一个。高手求救!!!

解决方案 »

  1.   

    你发错地方了,,自己在WEB开发中的JS脚本区发一个吧,,发错地方了
      

  2.   

    <HTML>
    <HEAD>
    </HEAD><BODY>
    <table>
    <tbody id="currow">
    <tr >
    <td >
    <input type="file" name="aa" onBlur="gao(event.srcElement);">
    </td>
    </tr>
    </tbody>
    </table>
    </BODY>
    </HTML>
    <script>
    function gao(obj){
    if(obj.tagName=='INPUT' && obj.type=='file'){
    if(obj.value != ""){
    newFile = document.getElementById('currow').firstChild.cloneNode(true);
    document.getElementById('currow').appendChild(newFile);
    }
    //alert(document.getElementById('currow').childNodes.length);
    if(obj.value == "")
    {
    for(i=0;i<document.getElementById('currow').childNodes.length;i++){
    document.getElementById('currow').removeChild(document.getElementById('currow').lastChild);
    }
    }
    }
    }
    </script>