:file selector

:file Selector

file selector

Description: Selects all elements of type file.

  • version added: 1.0jQuery( ":file" )

:file is equivalent to [type="file"]. As with other pseudo-class selectors (those that begin with a ":") it is recommended to precede it with a tag name or some other selector; otherwise, the universal selector ("*") is implied. In other words, the bare $( ":file" ) is equivalent to $("*:file" ), so $( "input:file" ) should be used instead.

登录查看完整内容