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 6 of 6

Thread: How to

  1. #1
    New to the CF scene
    Join Date
    Jul 2002
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question How to

    Hi,

    Since I am novice in java coding I need your help.
    I am using the "Drop in box" from Dynamic Drive Source.

    This is the body code:
    -----------------------------------
    <div id="dropin" style="position:absolute;visibility:hidden;left:250;top:100;width:500;height:300;background-color:#F5F5F5">
    <div align="right"><a href="#" onClick="dismissbox();return false">[Close Box] </a></div>
    SPECIFY YOUR CONTENT HERE. IT COULD BE TEXT, IMAGES, OR RICH HTML
    </div>
    -----------------------------------

    I want to when I click on the "close box" to close the box and the same time to open a new window to a www.somesite.com

    Is this possible?

    Thanks

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    The Netherlands, Baarn, Ut.
    Posts
    4,252
    Thanks
    0
    Thanked 0 Times in 0 Posts
    pinkopanter,

    i guess the simplest way would be to change the:
    Code:
    <a href="#"
    to
    Code:
    <a href="http://www.somsite.com"
    and to add
    Code:
    target="_blank"
    to it; that should still close the drop-in and at the same time open a new window with the desired site.
    Otherwise, you could use one of the open-a-window scripts that can be found on
    Javascript Kit. In that case, you'll have to add the function call that opens the window to the present onClick function call.
    Regards,
    Ronald.
    ronaldvanderwijden.com

  • #3
    New to the CF scene
    Join Date
    Jul 2002
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I try this but just closed the window, it didn't open the new window.

    Other ideas?

  • #4
    Regular Coder
    Join Date
    Jul 2002
    Location
    U.S. (Wish Japan though)
    Posts
    141
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hmmm...
    try this...
    Code:
    <a href="http://www.somepage.html" onclick="window.open(this.href); dismissbox();return false">[Close Box]</a>
    If that doesn't work, then please post the dismiss function, that way we can make up something to use in it..

  • #5
    Regular Coder
    Join Date
    Jul 2002
    Location
    U.S. (Wish Japan though)
    Posts
    141
    Thanks
    0
    Thanked 0 Times in 0 Posts

  • #6
    New to the CF scene
    Join Date
    Jul 2002
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    It works, thank you.

    See it in action: http://www.apictures.com/index.php


  •  

    Posting Permissions

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