Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 40b4f4e54e
Fetching contributors…

Cannot retrieve contributors at this time

10 lines (7 sloc) 0.697 kb

feature: input[placeholder] status: use tags: gtie9 kind: html polyfillurls:Placeholder jQuery Plugin

Input placeholders are simply ignored in IE 9 and below. Note that they are only applied when the type of the input is text, password, search, tel, url, or email. Textareas can have placeholders, too. Otherwise, it is ignored.

input[placeholder] is commonly the first polyfill anyone writes and, as such, there are many of them. Password inputs and submit event clearing are among many of the gotchas that catch naive implementations; Mathias's polyfill below handles these cases very well.

Jump to Line
Something went wrong with that request. Please try again.