Jquery attribute name filtering + Video-JS
Can you use Jquery attribute name filtering to select all Video-JS videos on a page and pausing them?
i'm using this to select all id's ending on _panel_movie_m4v and pausing them:
$('[id$=_panel_movie_m4v]')[0].pause();
But it won't work. if i use the full 开发者_开发技巧selector however, everything works fine...
$("#world_map_8_panel_movie_m4v")[0].pause();
try this:
$('[id$="_panel_movie_m4v"]')[0].pause();
It's looks like id's generated by asp.net. If you have full control over generated html (for example is generated using repeater) I suggest to create dedicated attributes or adding specific css class for items you would like to select.
精彩评论