Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <title></title>
- <script type="text/javascript" src="http://code.jquery.com/jquery-latest.pack.js"></script>
- <script type="text/javascript" src="popup.js"></script>
- <link rel="stylesheet" type="text/css" media="all" href="style.css" />
- <script>
- var tag = document.createElement('script');
- tag.src = "http://www.youtube.com/player_api";
- var firstScriptTag = document.getElementsByTagName('script')[0];
- firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
- var player;
- function onYouTubePlayerAPIReady() {
- player = new YT.Player('player', {
- height: '390',
- width: '640',
- videoId: 'u1zgFlCw8Aw',
- events: {
- 'onStateChange': onPlayerStateChange
- }
- });
- }
- function onPlayerReady(event) {
- event.target.playVideo();
- }
- var done = false;
- function onPlayerStateChange(event) {
- if (event.data == YT.PlayerState.PLAYING && !done) {
- done = true;
- }
- }
- function stopVideo() {
- player.stopVideo();
- }
- </script>
- </head>
- <body>
- <!-- #dialog is the id of a DIV defined in the code below -->
- <a href="#dialog" name="modal">clip 1</a><br /><br />
- <a href="#dialog2" name="modal">clip 2</a>
- <div id="boxes">
- <!-- #customize your modal window here -->
- <div id="dialog" class="window">
- <h1>Clip 1</h1>
- <div id="player"></div>
- <!-- close button is defined as close class -->
- <a href="#" class="close">Fermer</a>
- </div>
- <div id="dialog2" class="window">
- <h1>Clip 2</h1>
- <div id="player"></div>
- <!-- close button is defined as close class -->
- <a href="#" class="close">Fermer</a>
- </div>
- <!-- Do not remove div#mask, because you'll need it to fill the whole screen -->
- <div id="mask"></div>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement