Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Aug 2002
    Location
    Scotland
    Posts
    35
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy opening a link in a different window

    Basically i want a link to load in a different window from the one that the code is in. I am using frames to display the pages. I know that in HTML you would just use target = "page address" but I don't know how to put that into the code below which is in Javascript. Please help Thankyou


    function checkfordeath () {
    if ((hungerValue == 0) && (moodValue == 0) && (healthValue == 0) && (fitnessValue == 0) && (energyValue == 0)) {
    window.location.href = "yourpage.htm"
    }
    }

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    41° 8' 52" N -95° 53' 31" W
    Posts
    3,660
    Thanks
    0
    Thanked 0 Times in 0 Posts
    top.framename.location = "yourpage.htm"
    Former ASP Forum Moderator - I'm back!

    If you can teach yourself how to learn, you can learn anything. ;)


  •  

    Posting Permissions

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