Having never embedded video in a modal I am going to go on a whim and say 
that the modal is just hiding from the DOM and is still very present. 

Consider trying to use one of the events on the modal to call a stop on the 
video somehow when the modal hides or is hidden.  Again, this is 
hypothetical at this point since I have not tried this myself. 

A quick Google search shows this

http://stackoverflow.com/questions/1094397/how-can-i-stop-a-video-with-javascript-in-youtube

Good Luck, Nick

On Thursday, August 22, 2013 12:09:06 PM UTC-7, Involute wrote:
>
> So I use the following code to open a modal window (Bootstrap 2.3.2) to 
> display a Youtube video.  The user clicks play in the Youtube player and 
> the video plays fine.  If he clicks on the window's close button, however, 
> the window closes but the audio from the video continues.  The only way to 
> make it stop is to reopen the window, hit pause, and then close.  How can I 
> get the video to stop simply by clicking close?  Thanks.
>
>       <article class="span6 offset3">
>             <img src="img/WhoFirst button_thumb.jpg"><em>Who's On 
> First?</em> (watch the <a href="#launch" data-toggle="modal">movie</a>)
>             <section id="launch" class="modal hide fade">
>                 <header class="modal-header">
>                     <h3>Who's On First?</h3>
>                     </header>
>                     <div class="modal-body">
>                     <center><iframe width="480" height="360" src="
> http://www.youtube.com/embed/Dw_2hD3D1Yg"; frameborder="0" 
> allowfullscreen></iframe></center>
>                     </div>
>                     <footer class="modal-footer">
>                     <button class="btn btn-primary" 
> data-dismiss="modal">Close</button>
>                     </footer>
>                 </section>
>             </article>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"twitter-bootstrap" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to