Last active
August 29, 2015 13:56
-
-
Save dtaniwaki/9015023 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Wrap file input like this. | |
* <span class="file-wrapper"> | |
* <span class="class-for-your-custom-button">Choose a Photo</span> | |
* <input type="file" name="photo" id="photo" /> | |
* </span> | |
*/ | |
.file-wrapper { | |
cursor: pointer; | |
overflow: hidden; | |
position: relative; | |
display: inline-block; | |
vertical-align: baseline; | |
zoom: 1; | |
*display: inline; | |
*vertical-align: auto; | |
} | |
.file-wrapper input { | |
cursor: pointer; | |
font-size: 100px; | |
height: 100%; | |
filter: alpha(opacity=1); | |
-moz-opacity: 0.01; | |
opacity: 0.01; | |
position: absolute; | |
right: 0; | |
top: 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment