h3ad8ang3r
01-28-2005, 06:49 PM
I am making a website for my band. It's is almost done except for the scrolling in the iframes. I didn't like the ugly scrollbars because I use Firefox and they can't be customized with FF. So instead of scrollbars, I am using a script which scrolls the iframe using onmouseover/onmouseout when you hover over a link/image.
This is at the bottom of my index.htm, right before the closing body tag.
<script language="javascript">
<!--
upme=""
downme=""
function up(){
parent.left.window.scrollBy(0,-10)
upme=setTimeout("up()",100)
}
function down(){
parent.left.window.scrollBy(0, 10)
downme=setTimeout("down()",100)
}
function stopme(){
clearTimeout(upme)
clearTimeout(downme)
}
// -->
</script>
And these are the images
<img src="images/up.gif" height="25" width="25" border="0" onmouseover="up()" onmouseout="stopme()" hspace="0" vspace="0">
<img src="images/down.gif" height="25" width="25" border="0" onmouseover="down()" onmouseout="stopme()" hspace="0" vspace="0">
However, the problem is that when I try to scroll one window, they both scroll. I want to scroll two iframes independent of eachother; I.E. scroll the left iframe with own up/down images (like it is now) and scroll the right iframe seperately with its own up/down images.
Does anyone know of a way to make the scripts in the left/right iframes unique of one-another so they scroll seperately? Or maybe a way to target the left/right irames seperately?
The website is http://winterofdiscontent.web1000.com
Thanks in advance for any contributions.
This is at the bottom of my index.htm, right before the closing body tag.
<script language="javascript">
<!--
upme=""
downme=""
function up(){
parent.left.window.scrollBy(0,-10)
upme=setTimeout("up()",100)
}
function down(){
parent.left.window.scrollBy(0, 10)
downme=setTimeout("down()",100)
}
function stopme(){
clearTimeout(upme)
clearTimeout(downme)
}
// -->
</script>
And these are the images
<img src="images/up.gif" height="25" width="25" border="0" onmouseover="up()" onmouseout="stopme()" hspace="0" vspace="0">
<img src="images/down.gif" height="25" width="25" border="0" onmouseover="down()" onmouseout="stopme()" hspace="0" vspace="0">
However, the problem is that when I try to scroll one window, they both scroll. I want to scroll two iframes independent of eachother; I.E. scroll the left iframe with own up/down images (like it is now) and scroll the right iframe seperately with its own up/down images.
Does anyone know of a way to make the scripts in the left/right iframes unique of one-another so they scroll seperately? Or maybe a way to target the left/right irames seperately?
The website is http://winterofdiscontent.web1000.com
Thanks in advance for any contributions.