Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@gneutzling
Last active December 18, 2015 13:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gneutzling/5793496 to your computer and use it in GitHub Desktop.
Save gneutzling/5793496 to your computer and use it in GitHub Desktop.
Exemplo de custom input file para o post no http://dailydevtips.com/
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Custom Input File</title>
<style type="text/css">
* {margin: 0; padding: 0;}
.input-file {
position: relative;
width: 200px;
height: 30px;
}
label, input {
display: block;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 30px;
}
label {
font: bold 12px/2.5 arial;
text-align: center;
text-transform: uppercase;
color: #fff;
background: red;
border-radius: 5px;
}
input {opacity: 0;}
</style>
</head>
<body>
<form action="javascript:;">
<div class="input-file">
<label for="file">Photo upload</label>
<input type="file" name="file" id="file">
</div>
</form>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment