input type file 获得用户选择的一般方法

时间:2014-07-20 23:21:24   收藏:0   阅读:408
<script type="text/javascript">
    function ShowExcelFile() {
        var tempName = $("#selectOriginFile_CertificationTemplateSelect").val();
        if (tempName != null && tempName != "") {
            window.open("/home/ReadExcelFile?filename=" + encode(tempName), excel文件显示, height=768, width=1024,fullscreen=no, scrollbars=auto);
        }
    }
</script>


<div style="width:100%;height:100%; text-align:center; padding-top:300px;">
     请选择原始数据文件:
     <br />
        <input type="file" id="selectOriginFile_CertificationTemplateSelect"  title="选择" />
    <br />

    <h1>显示选择的文件</h1>
    <input type="button" value="显示" onclick="ShowExcelFile() " />
</div>

input type file 获得用户选择的一般方法,布布扣,bubuko.com

原文:http://www.cnblogs.com/wangxiuhui/p/3857372.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!