1 year ago
#340687
JohnnyB
Putting images in one frame, click on image, have that image open in a different frame
I am trying to set up an image gallery that will allow an image from the middle frame to open open in the main frame. I have it set up right now to allow people to scroll the images down one frame. If I can get the image to open in another frame so people don't have to scroll back up to the top, that would be my end goal.
Thank you in advance for any and all help, this is what I have so far.
<script>
function myFunction(imgs) {
var expandImg = document.getElementById("expandedImg");
var imgText = document.getElementById("imgtext");
expandImg.src = imgs.src;
imgText.innerHTML = imgs.alt;
expandImg.parentElement.style.display = "block";
}
</script>
<a href="01.png" target="middle" onclick="myFunction(this);"> <img src="01.png" style="width:150px; height:150px;"> </a> <br>
The index page containing the frames info.
<FRAMESET ROWS="65px,*" frameborder="0">
<FRAME SRC="top.html" NAME=top scrolling="no">
<frameset cols="150,150,700" frameborder="0">
<frame src="content.html" name="content" scrolling="yes">
<frame src="middle.html" name="middle" scrolling="yes">
<frame src="main.html" name="main" scrolling="no">
</frameset>
</frameset>
javascript
html
image
hyperlink
gallery
0 Answers
Your Answer