SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast
    Join Date
    Jul 2000
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hello, does anyone know how to do this?

    This is the situation:

    You have a window with a maybe 10 or 20 links.

    Each link opens a pop up.

    What needs to be done is have each pop-up window automatically close upon clicking any link the parent window.

    I know I can use the <onBlur=selfclose> command for a pop-up to automatically close but I need it to close only if any one of the links is clicked in the parent window and not just if the window focus blurs from clicking on any window on the desktop.

    If there is a page default thing involved, how could this be done alternately by clicking some of the links in the parent window, not necessarily any link.

    Thanks for any suggestions/solutions.

  2. #2
    SitePoint Wizard creole's Avatar
    Join Date
    Oct 2000
    Location
    Nashvegas Baby!
    Posts
    7,845
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    you would need to access something like window.parent
    Adobe Certified Coldfusion MX 7 Developer
    Adobe Certified Advanced Coldfusion MX Developer
    My Blog (new) | My Family | My Freelance | My Recipes

  3. #3
    I believe you have my stapler. scrubz's Avatar
    Join Date
    Feb 2001
    Location
    Van down by the river
    Posts
    254
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    On the links in the parent window, call a function that checks to see if the child exists, and if so, close the child.

    <a href="blah.htm" onClick="closeChild();">blah</a>

    Then in the JavaScript closeChild function, check for the child window, and if it exists, do a childWindowName.close();


Bookmarks

Posting Permissions

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