참조 : http://tiagoe.blogspot.kr/2010/01/css-style-typefile-tags.html
//css
.file_input_textbox
{
float: left
}
.file_input_div
{
position: relative;
width: 100px;
height: 23px;
overflow: hidden;
}
.file_input_button
{
width: 100px;
position: absolute;
top: 0px;
background-color: #33BB00;
color: #FFFFFF;
border-style: solid;
}
.file_input_hidden
{
font-size: 45px;
position: absolute;
right: 0px;
top: 0px;
opacity: 0;
filter: alpha(opacity=0);
-ms-filter: "alpha(opacity=0)";
-khtml-opacity: 0;
-moz-opacity: 0;
}
// html
<input type="text" id="fileName" class="file_input_textbox" readonly="readonly">
<div class="file_input_div">
<input type="button" value="Search files" class="file_input_button" />
<input type="file" class="file_input_hidden" onchange="javascript: document.getElementById('fileName').value = this.value" />
</div>
'프로그래밍 > Html' 카테고리의 다른 글
multipart form data (0) | 2019.08.13 |
---|---|
simple table (아래 글의 css 적용) (0) | 2015.10.30 |
simple table css (0) | 2015.10.30 |
모바일웹에서 app 설치 확인 (0) | 2014.03.24 |
모바일 웹 (0) | 2014.03.24 |