Created
March 19, 2012 05:24
-
-
Save bradfrost/2096790 to your computer and use it in GitHub Desktop.
Center aligned placeholder text
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
/** | |
* Center aligned placeholder text | |
*/ | |
input { | |
box-sizing: border-box; | |
width: 100%; | |
padding: 1em; | |
border: 0.15em solid #808080; | |
border-radius: 0.5em; | |
text-align: center; | |
} | |
::-webkit-input-placeholder { | |
color: #808080; | |
text-align: center; | |
} | |
:-moz-placeholder { | |
color: #808080; | |
text-align: center; | |
} |
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
<form> | |
<input placeholder="Oh placeholder text, you sick son of a bitch" /> | |
</form> |
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
{"view":"split","seethrough":"","prefixfree":"1","page":"css"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment