findInPage

H

Henriksen

I have this :

<form name="search" onSubmit="return
window.opener.findInPage(this.string.value)">

But I would like to change it to search on the main frame,
from the menu frame.
Is that possible ?
 
M

Martin Honnen

Henriksen said:
I have this :

<form name="search" onSubmit="return
window.opener.findInPage(this.string.value)">

But I would like to change it to search on the main frame,
from the menu frame.
Is that possible ?

Well what is the relation between those two frames? Perhaps
return window.parent.frames.mainFrameName.findInPage(this.string.value)
is what you are looking for, if those two frames are in the same
frameset window.
 
H

Henriksen

Well what is the relation between those two frames? Perhaps
return window.parent.frames.mainFrameName.findInPage(this.string.value)
is what you are looking for, if those two frames are in the same
frameset window.

Thanx a lot, this works:
onSubmit="return
window.parent.frames.main.findInPage(this.string.value)">

But only in IE, not in FF .... any clue ?
 
M

Martin Honnen

Henriksen said:
onSubmit="return
window.parent.frames.main.findInPage(this.string.value)">

But only in IE, not in FF .... any clue ?

Well what exactly happens in FF? Do you get an error in the error
console? Which one exactly?
Do you have
<frame name="main" src="foo.html">
 
H

Henriksen

Well what exactly happens in FF? Do you get an error in the error
console? Which one exactly?
Do you have
<frame name="main" src="foo.html">
There are no errors in he console.

I testet the script, found on :
http://www.hypergurl.com/searchpage.html
Inside the page, but it does not work in FF,
so it has nothing to do with the frame,
but the frame version is better, because else you can only press
search one time, or as long the page does not scroll.
 
H

Henriksen

I testet the script, found on :
http://www.hypergurl.com/searchpage.html
Inside the page, but it does not work in FF,
so it has nothing to do with the frame,
but the frame version is better, because else you can only press
search one time, or as long the page does not scroll.

I found out:

I changed this:
if (NS4)

to this:
if (/Firefox[\/\s](\d+\.\d+)/.test(navigator.userAgent))
 
E

Erwin Moller

Henriksen schreef:
I testet the script, found on :
http://www.hypergurl.com/searchpage.html
Inside the page, but it does not work in FF,
so it has nothing to do with the frame,
but the frame version is better, because else you can only press
search one time, or as long the page does not scroll.

I found out:

I changed this:
if (NS4)

to this:
if (/Firefox[\/\s](\d+\.\d+)/.test(navigator.userAgent))

WHAT did you find out?


Erwin Moller

--
"There are two ways of constructing a software design: One way is to
make it so simple that there are obviously no deficiencies, and the
other way is to make it so complicated that there are no obvious
deficiencies. The first method is far more difficult."
-- C.A.R. Hoare
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,116
Messages
2,570,699
Members
47,274
Latest member
SeleneHgw8

Latest Threads

Top