View Full Version : changing scrollbar for firefox & targeting two different frames from one button
jinzen
September 10th, 2007, 09:46 PM
I was wondering if you can change the default appearance of the scrollbar for firefox users.
As for my second question. This is what i'm trying to do. The layout of my website has 1 row (top) and 3 columns (left, middle, right). When i click a button (from the left frame), i want the top and middle frames to change at one time. I'm a newb at coding, so can you please post the code to help me understand.
Is there a limit on how long a code is for one page? As i'm copying and pasting over and over again the same code for a list of text, as i get farther and farther, the code starts to mess up and doesn't work. Its very frustrating because i can't get exactly what i have at the top of the page for the bottom.
RabBell
September 11th, 2007, 07:13 AM
I was wondering if you can change the default appearance of the scrollbar for firefox users.
Not for FireFox, no. IE, yeah you can change it for IE but not Firefox.
As for the frames have a look at this example on w3schools
http://www.w3schools.com/html/tryit.asp?filename=tryhtml_frame_navigation
Click the frame a, frame b and frame c and the contents of the frame on the right will change. The code for the a, b and c links are below
<html>
<body>
<a href ="frame_a.htm" target ="showframe">Frame a</a><br>
<a href ="frame_b.htm" target ="showframe">Frame b</a><br>
<a href ="frame_c.htm" target ="showframe">Frame c</a>
</body>
</html>
If you're looking to change two at once then what you want is this...
<html>
<head>
<script language="JavaScript">
function gotolink()
{
document.showframe.location.href = "frame_b.htm"
document.thesecondframe.location.href = "whatever.htm"
}
</script>
</head>
<body>
<a href ="frame_a.htm" target ="showframe">Frame a</a><br>
<a href ="frame_b.htm" target ="showframe">Frame b</a><br>
<a href ="frame_c.htm" target ="showframe">Frame c</a><br>
<a href ="javascript:gotolink()">2 Frames</a>
</body>
</html>
hope something above helps
jinzen
September 11th, 2007, 06:00 PM
<html>
<head>
<script language="JavaScript">
function gotolink(Do i put something between here?)
{
document.showframe.location.href (Location as in the url?)= "frame_b.htm"
document.thesecondframe.location.href = "whatever.htm"
}
</script>
</head>
<body>
<a href ="frame_a.htm" target ="showframe">Frame a</a><br>
<a href ="frame_b.htm" target ="showframe">Frame b</a><br>
<a href ="frame_c.htm" target ="showframe">Frame c</a><br>
<a href ="javascript:gotolink(Do i put something between here?)">2 Frames</a>
</body>
</html>
Do i put this code where my button is? More questions above within the code (in bold). I'm a bit confused where to put what, so i'll post my code and hopefully we can figure it out.
My menu page
<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY BGCOLOR="#000000">
<div align="left">
<a href="middle.html" target="middle"><img src="home.jpg" border="0"> This is the button so when its clicked, the top and middle change at the same time.
<a href="navi.html" target="right"><img src="news.jpg" border="0">
<a href="epguide.html" target="middle"><img src="epguide.jpg" border="0">
<a href="epguide.html"><img src="forums.jpg" border="0">
<a href="epguide.html"><img src="fanart.jpg" border="0">
<a href="epguide.html"><img src="about.jpg" border="0">
<a href="epguide.html"><img src="contact.jpg" border="0">
</div>
</BODY>
</HTML>
My index page
<html>
<head>
<title></title>
</head>
<frameset rows="200,*" frameborder="no">
<frame src="top.html" name="top">
<frameset cols="20%,60%,20%">
<frame src="menu.html" name="left">
<frame src="middle.html" name="middle">
<frame src="navi.html" name="right">
</frameset>
</html>
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.