Results 1 to 6 of 6

Thread: How do I make a button target a certain frame in a frames page?

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Aug 2001
    Posts
    28

    How do I make a button target a certain frame in a frames page?

    How do I make a button target a certain frame in a frames page?

  2. #2
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    in what sense?
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Aug 2001
    Posts
    28
    If there is a button in frame a, when clicked a link opens up in frame b.

  4. #4
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    Code:
    <input type="button" name="cmdLink" value="Click" onClick="document.frames.b.location.href='http://www.yahoo.com'; return true">
    I think will do it

    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  5. #5
    Fanatic Member chrismitchell's Avatar
    Join Date
    Jan 2001
    Location
    With Hobbes in New Zealand
    Posts
    568
    crptcblade, you are right about the onClick="document.frames.b.location.href...."

    but doesn't it need to have javascript:(all one word) before the document.frames.... ?

  6. #6
    Fanatic Member gwdash's Avatar
    Join Date
    Aug 2000
    Location
    Minnesota
    Posts
    666
    no, only if its the href of a link, onclick doesn't, ie:

    <a href="javascript:history.back();">Go Back</a>

    vs.

    <a href="" onclick="history.back();">Go Back</a>
    GWDASH
    [b]VB6, Perl, ASP, HTML, JavaScript, VBScript, SQL, C, C++, Linux , Java, PHP, MySQL, XML[b]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width