Source Code:
(back to article)
Submit
Result:
Report an issue
<!DOCTYPE html> <html> <head> <title>Title of the document</title> <style> .container { display: flex; align-items: flex-start; justify-content: flex-start; width: 100%; } input[type="file"] { position: absolute; z-index: -1; top: 10px; left: 8px; font-size: 17px; color: #b8b8b8; } .button-wrap { position: relative; } .button { display: inline-block; padding: 12px 18px; cursor: pointer; border-radius: 5px; background-color: #8ebf42; font-size: 16px; font-weight: bold; color: #fff; } </style> </head> <body> <div class="container"> <div class="button-wrap"> <label class="button" for="upload">Upload File</label> <input id="upload" type="file"> </div> </div> </body> </html>