I have a website with a map. At certain spots I have a rollover image that links to a short video. Using target=" _blank" creates a new tab; using nothing has the video playing in the same size page.
Question? Can I define the size of the new page or tabbed page to something like 80% of parent page.
Thank you for your time and possible solution.
Code below is what I have that creates a same size tab
<div id="apDiv3"><a href="Fork at 57km.mp4" target="_blank" onmouseover="MM_swapImage('fork 57','','fork 57.jpg',1)" onmouseout="MM_swapImgRestore()"><img src="Rollover blankBL.png" alt="Fork at 5.7 Km stay right" width="400" height="225" id="fork 57" /></a></div>
I like using css modalDialog for these kinds of things. Very easy to add in loops by just incrementing the id. I use it often on calendars etc. Hereās a basic sample page called modaltestpage.html.
I appreciate the time you spent making this response, This and the previous solution look interesting and I will try both of them to see which suits my needs best.
Thank you.
Thank you again Drumminā¦ but
I like the idea you have proposed but am having difficulty in understanding and implementing it. Where is the association with #viewvideo1 and my Fork at 57km.mp4 come from? Do I need to define a list or something? How?? Do I change the name of modaltestpage.html?
Could I trouble you to edit your code to show where and how my sample would fit in?
Thank you so much for taking your time with this.
The name of the page doesnāt matterā¦ just change it to the same in all instances. You donāt need to make a list but each reference id needs to be unique in the call url #video1, #video2 etc and have a matching id , e.g. <div id="video1" class="modalDialog">
In each of these divisions you define the popup as you like. If you wish to have the video title in the h2 tags you could do that or remove h2 tags. I would put the video player code in the wrapper <div class="modalinnerwrapper"> with whatever video is to play, e.g. Fork at 57km.mp4 or whatever.
So going with info I have it would be like this
<div id="apDiv3"><a href="modaltestpage.html#Forkat57" onmouseover="MM_swapImage('fork 57','','fork 57.jpg',1)" onmouseout="MM_swapImgRestore()"><img src="Rollover blankBL.png" alt="Fork at 5.7 Km stay right" width="400" height="225" id="fork 57" /></a></div>
<div id="Forkat57" class="modalDialog">
<div>
<a href="modaltestpage.html" title="Close" class="close">X</a>
<h2>Fork at 57</h2>
<div class="modalinnerwrapper">
video player goes here playing Fork at 57km.mp4
</div>
</div>
</div>
Also note that the links section and modalDialog divās donāt need to be in the same section as in my first example. So your āmapā links section doesnāt need to change much besides changing the links and removing target. The modalDialog divās can be defined in a different part of the page after displayed content. Using original example.
<div id="viewvideo1" class="modalDialog">
<div>
<a href="modaltestpage.html" title="Close" class="close">X</a>
<h2>Viewing Video One</h2>
<div class="modalinnerwrapper">
My video One plays here
</div>
</div>
</div>
<div id="viewvideo2" class="modalDialog">
<div>
<a href="modaltestpage.html" title="Close" class="close">X</a>
<h2>Viewing Video Two</h2>
<div class="modalinnerwrapper">
My video Two plays here
</div>
</div>
</div>