473,387 Members | 1,721 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Javascript in frames

Been at this for 3 days. Have no hair left. It's gotta be simple.
Can anyone help?

I have a frameset with four frames:

<frameset cols="150,*">
<frame name="top" src="gallery1a.htm">
<frameset rows="33%,33%,*">
<frame name="left" src="gallery1b.htm" scrolling="yes">
<frame name="middle" src="gallery1c.htm">
<frame name="bottom" src="gallery1d.htm">
</frameset>
</frameset>
frame name"gallery1a.htm" holds thumbnails.

When you click a thumbnail, a large image should manifest in frame
name"gallery1c.htm"

Here's what I'm using in tables, and it works fine:

<td valign=top width=150><center>
<IMG SRC="test1b.gif" width=90
ONMOUSEdown="document.images['large'].src= 'test1b.gif'">
</td>
<td valign=top width=500><center>
<IMG SRC="space.jpg" NAME="large">
</td>

But how do I transpose that code so I'm calling to another frame, not
another table? Can anyone give me the exact syntax, per the above?

Any help hugely appreciated!

Jul 23 '05 #1
2 1491
semantiks wrote:
Been at this for 3 days. Have no hair left. It's gotta be simple.
Can anyone help?

I have a frameset with four frames:

<frameset cols="150,*">
<frame name="top" src="gallery1a.htm">
<frameset rows="33%,33%,*">
<frame name="left" src="gallery1b.htm" scrolling="yes">
<frame name="middle" src="gallery1c.htm">
<frame name="bottom" src="gallery1d.htm">
</frameset>
</frameset>
frame name"gallery1a.htm" holds thumbnails.

When you click a thumbnail, a large image should manifest in frame
name"gallery1c.htm"

Here's what I'm using in tables, and it works fine:

<td valign=top width=150><center>
<IMG SRC="test1b.gif" width=90
ONMOUSEdown="document.images['large'].src= 'test1b.gif'">
</td>
<td valign=top width=500><center>
<IMG SRC="space.jpg" NAME="large">
</td>

But how do I transpose that code so I'm calling to another frame, not
another table? Can anyone give me the exact syntax, per the above?

First of all rename your "top" frame ("top" is a reserved word)

<IMG SRC="test1b.gif"
onclick="top.frames['middle'].document.images['large'].src= 'test1b.gif'">

This assumes you have an image with the name "large" in "gallery1c.htm"
document.

Mick

Jul 23 '05 #2
ASM
semantiks wrote:
<frameset cols="150,*">
<frame name="top" src="gallery1a.htm">
<frameset rows="33%,33%,*">
<frame name="left" src="gallery1b.htm" scrolling="yes">
<frame name="middle" src="gallery1c.htm">
<frame name="bottom" src="gallery1d.htm">
</frameset>
</frameset>

frame name"gallery1a.htm" holds thumbnails.
no !
frame "top" containing "gallery1a.htm" that holds thumbnails.
or
"gallery1a.htm" from frame "top" holds thumbnails.
When you click a thumbnail, a large image should manifest in frame
name"gallery1c.htm"

Here's what I'm using in tables, and it works fine:

<td valign=top width=150><center>
<IMG SRC="test1b.gif" width=90
ONMOUSEdown="document.images['large'].src= 'test1b.gif'">
It is a non-sens to enlarge a small image
It is a non-sens to show a big image as a thumbnail

you have to do 2 images : a small (thumbnail) and a tall (big)
</td>
<td valign=top width=500><center>
<IMG SRC="space.jpg" NAME="large">
</td>

But how do I transpose that code so I'm calling to another frame, not
another table? Can anyone give me the exact syntax, per the above?

Any help hugely appreciated!


<IMG SRC="test1b.gif" width=90
onclick="parent.middle.document.images['large'].src='bigs/'+this.herf;
return false;">

(hope that "gallery1c.htm" as 1 free image named 'large')

or even without JS

<IMG SRC="big/test1b.gif" target="middle"><img src="small/test1b.gif></a>
--
Stephane Moriaux et son [moins] vieux Mac
Jul 23 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: ÂÑTØÑ | last post by:
Hi, I was looking for a list of commands, but I can't find it. It's about commands you can type in the Internet Explorer adress bar, to get some information about a website. For instance...
4
by: JesusFreak | last post by:
From: us_traveller@yahoo.com (JesusFreak) Newsgroups: microsoft.public.scripting.jscript Subject: toolbar script problem NNTP-Posting-Host: 192.92.126.136 Recently, I downloaded the following...
7
by: Bert | last post by:
I have been reading the post and the FAQ and have been unable to find anything that will help with my problem. First let me say that I am not a web developer, designer and no next to nothing...
3
by: John Bokma | last post by:
I have two windows in a frame. I want to be able that each can open a pop up window and that the handle to that window can be stored somewhere, so that each can talk to the pop up. is it...
3
by: dricks dr | last post by:
Hi, I'm using the AxWebBrowser Control from microsoft in a C# application. It works fine, but i have many problems to hide the javascript error windows that appear when u visit a website with......
3
by: krishna | last post by:
Below is the code. language = asp.net/vb.net private sub openW() sResult = sResult & "<script language=javascript> mywindow =...
3
by: jimmygoogle | last post by:
I posted earlier with a scope problem. I think I resolved it in IE but in Firefox it still exists. Anyone have any ideas/experience with this? I attached my code sorry it is so long. You can...
2
by: KC | last post by:
Hi, Every JavaScript executive context has a top-level window and we can use window.open() to open another window ... Does this related to Windows created by click on "File"->"New Window" or...
3
by: mportman300 | last post by:
Have pity on me.. i have been doing html, css, javascript squarely over 2 years... and am now doing a family project.. in my project i have decided to use a context menu script, its a menu that...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.