Click to See Complete Forum and Search --> : Using a Back Button with Frames


jskeens
04-17-2003, 03:48 PM
Okay everyone I have a good one here, hope someone can give me some good insight on this one.

I am working on a report page that has 3 separate frames on it. What I am looking to do is, to get the back button that is a part of Explorer itself to take me back or redirect me to my main report page, NOT the one that is currently using the 3 frames.

What is happening currently when I click the back button in Explorer is, everyone of the frames goes back one page. So if I look at 3 reports it flips through the previous 2 reports, I dont want that. I want it to redirect me too my main report selection page.

Is this possible and if so how can I do it?

I can disable Explorer buttons so I dont see why I can not change what they are doing.

EXoCiDe
04-17-2003, 06:40 PM
try using the right mouse button on the frame you want, and click Back on the menu that pops up.

jskeens
04-18-2003, 07:04 AM
Thanks for the information but that is not what I am looking to do.

Vladdy
04-18-2003, 07:19 AM
The best thing is not to use frames at all.
Also, you can not change the behaviour of browser buttons. The only thing I can think of (which I never tried) is every time you navigate through your frames you clear the history hoping that browser back button will stay disabled and forcing users to use your "back" button.

jskeens
04-18-2003, 08:22 AM
Okay well I have pretty much given up on changing the functionality of the back button itself.

There is no way around using frames, I have too, that is just how the page works. But is there a way to say in the frameset that when the back button is clicked that I redirect to a certain page? Kind of hard code in what I want it to do in the page??

Vladdy
04-18-2003, 09:32 AM
Originally posted by jskeens
There is no way around using frames...
There is always a way around frames!!! Any page can be designed without them. What are using them for? layout - just use absolutely positioned div if keeping banner and nav in the view is that important; loading files? - use iframe or object.

jskeens
04-18-2003, 09:37 AM
I am using 3 active pages in one page. One frame to list the 100's of reports, another frame to give me the report params for the report I selected and the last one to show me a preview of the report.

Is there a way to do what I want to do? And if so how? I am about to go out of my mind trying to get it to work.

Vladdy
04-18-2003, 11:19 AM
What are the report params? Is it the output that represents report or input that influences how the report is generated? Also what are your browser compatibility reqs?

jskeens
04-18-2003, 11:26 AM
I dont want to go into the whole functionality of the page, I would just like an answer on my original question, if someone can give that to me please.

jskeens
04-18-2003, 02:23 PM
Someone , Anyone HELP PLEASE!!!!!!

Vladdy
04-18-2003, 02:30 PM
I tried :rolleyes:

EXoCiDe
04-20-2003, 02:53 AM
some people are so stubborn. anyways, do this:
put a "Back" link on each page with <a href="javascript:history.back(1)"> maybe that will work.
if it doesnt work, try putting target="FRAME NAME" in the tag above.

Nevermore
04-20-2003, 07:17 AM
This code will send the browser to your mainpage unless they entered your page by clicking on a link:
Just place this code as the body tag:

<body onload="javascript:if(!document.referrer) window.location.href='index.html'">

EDIT: You will need to join the words java and script together - the server separates them to stop the script running in the forum.

AWhiteC
04-20-2003, 09:01 AM
Originally posted by Vladdy
... just use absolutely positioned div if keeping banner and nav in the view is that important; ...

What's the markup for an "absolutely positioned div"?

Nevermore
04-20-2003, 09:13 AM
Originally posted by AWhiteC:
What's the markup for an "absolutely positioned div"?

<div style="position:absolute; left=10px; right=10px;"></div>

Just substitue in your own values for left and top - these are the distances from the left and top of the window.