How to implement a responsive Youtube embed iframe with Twitter Bootstrap?

后端 未结 6 1951
忘了有多久
忘了有多久 2021-01-30 14:10

Currently I\'m embedding Youtube videos with the following HAML code in a Twitter Bootstrap based site:

.row
  .span12
    %iframe.span11{ :height => \"720\",         


        
6条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-30 14:42

    Just to automatize @Bart's answer, I've created a simple Javascript snipped that automatically wraps iframe elements within

    $(document).ready(function() {
      $('iframe').each(function() {
        $(this).wrap('
    '); }); });

提交回复
热议问题