SitePoint Sponsor

User Tag List

Results 1 to 7 of 7

Hybrid View

  1. #1
    SitePoint Zealot
    Join Date
    Apr 2001
    Location
    home
    Posts
    132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Window Close Function in Firefox 2.0.x?

    Does anyone know of a chunk of JavaScript that will succesfully close a Firefox 2.0.x window?

    I'm trying to set up a close window link in a web page and everything I've found related to Firefox was for older versions of Firefox, but there isn't anything that seems to work in Firefox 2.0.x.

  2. #2
    In memoriam gold trophysilver trophybronze trophy Dan Schulz's Avatar
    Join Date
    May 2006
    Location
    Aurora, Illinois
    Posts
    15,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm not a JavaScript expert, so I may not be of much use to you, but can you post the code you're using?

  3. #3
    SitePoint Member talktechno's Avatar
    Join Date
    Apr 2006
    Posts
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i have also noticed this doesnt work in firefox, works fine in IE though

  4. #4
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    window.close() works fine. Please post code that proves the opposite.

  5. #5
    SitePoint Zealot
    Join Date
    Nov 2005
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    self.close() also works

  6. #6
    SitePoint Guru
    Join Date
    Apr 2007
    Posts
    813
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    how if there are multiple tabs opened? will that close the all the tabs?

  7. #7
    SitePoint Zealot
    Join Date
    Nov 2005
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by SimplyFu View Post
    how if there are multiple tabs opened? will that close the all the tabs?
    Nope, window.close() or self.close() just closes the page its on


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
  •