原生input[file]組件樣式美化

基本上有三種方法能夠實現 經過 opacity:0 和定位隱藏就能夠在使用button的美化樣式和input[file]的功能。 <div class="upload"> <button></button> <input type="file" name="file" id="file"> </div> <style> #file{ position:absolute; left:0; rig
相關文章
相關標籤/搜索