??浠??ㄥ??琛ㄥ???????典?锛?input??textarea??button???峰?姣?杈?瀹規??瀹?涔?锛?select??input file???峰??句互瀹?涔???
?
input file?ㄧ郴缁?榛?璁や???澶?瑙?锛?
?
??浠???澶???杩?瀹?涔?input??border?ユ?瑰??绯葷?榛?璁ょ??澶?瑙?锛?
?
濡???瑕?璁╂?瑙??????存?浜?涓??癸???浠??沖??涔?瀹???????棰??詫????蟲?崇?ㄨ?????劇???ヤ唬?匡???杩?css瀹?涔?input flie杩???????涓??扮?????剁?剁???頒?绡???绔?锛?input file ??浠堕???╂?缇??? 浣???????绯葷?榛?璁ょ??????璁劇疆????搴?負0锛???瀹?涔?涓?涓?label??绛炬?峰?锛??ヨ?????????????????
???т??????規?锛???涔?璇?楠?浜?涓?涓?锛?浠g??濡?涓?锛?
?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>input file????被??娉?</title>
<style type="text/css">
<!--
* { font-size:12px}
body { margin:0}
.line { position:relative; float:left; padding:8px 0}
.line span { float:left}
input { border:1px solid #888; vertical-align:middle}
.file { position:absolute; left:90px; top:8px; display:none;filter:alpha(opacity=0);opacity:0}
.file1 { padding:2px 10px; display:block; float:left; background:#FF66CC; color:#fff; z-index:1; margin-left:5px; vertical-align:middle; cursor: pointer}
.inputstyle { width:150px; border:1px solid #888; z-index:99}
-->
</style>
</head>
<body>
<div class="line"> <span>
<label>涓?浼???浠訛?</label>
<input name="" type="text" id="viewfile" 慰nm慰use慰ut="document.getElementById('upload').style.display='none';" class="inputstyle" />
</span>
<label for="unload" 慰nm慰use慰ver="document.getElementById('upload').style.display='block';" class="file1">娴?瑙?...</label>
<input type="file" 慰nchange="document.getElementById('viewfile').value=this.value;this.style.display='none';" class="file" id="upload" />
</div>
</body>
</html>
?