Solved

Send page to Top Frame

Posted on 2000-03-08
3
185 Views
Last Modified: 2012-08-13
I have the following javascipt, how can I get this page to open in the top frame?

<script language="JavaScript">
function submitform() {
        document.FmRouter.action="../Charts/IT_Customers_Rtr.cfm?Router=#Form.SelRouter#&TimeSpan=#Form.TimeSpan#"
       document.FmRouter.submit();
     return true;
   }  
</script>
0
Comment
Question by:cb1
  • 2
3 Comments
 
LVL 33

Expert Comment

by:knightEknight
Comment Utility
In the form tag, set the target attribute:

<FORM name='FmRouter' target='NameOfYourTopFrame' action='whatever' method='post'>

.... just don't name your top frame "top" because that is a javascript keyword.
0
 
LVL 8

Expert Comment

by:xabi
Comment Utility
document.FmRouter.target = "_top"

xabi
0
 
LVL 8

Accepted Solution

by:
xabi earned 50 total points
Comment Utility
<script language="JavaScript">
function submitform() {
        document.FmRouter.action="../Charts/IT_Customers_Rtr.cfm?Router=#Form.SelRouter#&TimeSpan=#Form.TimeSpan#"
document.FmRouter.target = "_top"
document.FmRouter.submit();
     return true;
   }    
</script>

xabi
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

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

771 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

10 Experts available now in Live!

Get 1:1 Help Now