Solved

history.go(-1) for another frame

Posted on 2001-08-31
7
225 Views
Last Modified: 2010-05-19
I have 2 frame. Frame A is for navigation button including back button that works exactly like the browser.
and Frame B is the content of the website.

Question:
How to create a back button that can go to the previous page of the frame B?

TIA
0
Comment
Question by:hdrik
  • 4
  • 3
7 Comments
 
LVL 19

Accepted Solution

by:
DreamMaster earned 100 total points
ID: 6443920
<a href="javascript:parent.frameB.history.go(-1)">Go back on Frame B</a>

Max.
0
 

Author Comment

by:hdrik
ID: 6444047
Max, it didn't work.
0
 
LVL 19

Expert Comment

by:DreamMaster
ID: 6444058
Hmm...can you show me the source of your frameset?

It should work...so I want to check...

Max.
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:hdrik
ID: 6444082
----- MAIN.HTML ---
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE></TITLE>
<META content="text/html; charset=windows-1252" http-equiv=Content-Type>
</HEAD>

<FRAMESET cols="100%" rows="10%,*">
  <FRAME marginHeight=1 name=frameA Resize src="navigate.html">
  <FRAME marginHeight=1 name=frameB Resize src="http://myserver/default.asp">
  <NOFRAMES>You must use a browser that can display frames to see this page. </NOFRAMES>
</FRAMESET>
</HTML>

----- NAVIGATE.HTML ---
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Feedback System</TITLE></HEAD>
<BODY>
<A href="Javascript:parent.frames('frameB').history.go(-1)">BACK</A>

</BODY>
</HTML>

0
 
LVL 19

Expert Comment

by:DreamMaster
ID: 6444100
It will work if you load a new page into it first...if you are opening the frameset and try to go back immediately...there's nothing in the history of the frame...as soon as there is...it will be no problem....just tried it out myself..and it works...

Max.
0
 

Author Comment

by:hdrik
ID: 6444105
sorry my mistakes.. it works.. Thanks Max..
0
 
LVL 19

Expert Comment

by:DreamMaster
ID: 6444112
Anytime hdrik... :)

Thanks for the grade A... :)

Max.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Introduction The Google Maps API offers various ways to draw dynamic and static maps.  Using a combination of PHP and JavaScript, you can draw active JavaScript maps that allow pan-and-zoom in the client browser window.  You can also draw "static" …
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now