Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using buttons in a frameset page

Status
Not open for further replies.

crystalb24

Programmer
Aug 31, 2004
75
US
I'm trying to use buttons to direct users through pages in a frameset using this code:

Code:
<input name="button 1" type="button" class="style20" onClick="MM_goToURL('parent','instructions.htm');return document.MM_returnValue" value="First Time User">

but when it redirects to the URL it does so outside of the frameset. I need it to target to "_mainFrame", but I'm not familiar enough with button tags to know how to do this.

~Crystal
Click here ( for a free iPod
 
At a glance, try changing
Code:
MM_goToURL('parent','instructions.htm')
to
Code:
MM_goToURL('[red]_mainFrame[/red]','instructions.htm')

--Chessbot

"See the TURTLE of enormous girth!"
-- Stephen King, The Dark Tower series
 
Crystal - it depends on the code inside your function.

Just from guessing, I would assume the first parameter you're passing in is the target. If this is so, call the function like this:

Code:
onclick="MM_goToURL('_mainFrame','instructions.htm'); return document.MM_returnValue;"

*cLFlaVA
----------------------------
"Holy crip he's a crapple!
 
neither way works, i had tried changing 'parent' to '_mainFrame', hoping that it would be that simple but no luck, and adding 'target="_mainFrame"' has no effect. i'm wondering if it might be easier to use an image instead of a button and link that way?

~Crystal
Click here ( for a free iPod
 
We're gonna need to see the code of your function.

*cLFlaVA
----------------------------
"Holy crip he's a crapple!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top