Web Analytics Made Easy -
StatCounter Pop-up without menus, etc. - CodingForum

Announcement

Collapse
No announcement yet.

Pop-up without menus, etc.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Pop-up without menus, etc.

    I am using a script to open a window with the full size picture when someone clicks the thumbnail. Easy enough, works great. This script I'm using opens a window to fit the dimensions of the image, however, it includes the full complement of browser accessories, i.e. menus, address line, scrollbars, etc. I'd prefer to have it open to the size of the image, with nothing but the title bar. Can I add something to this script that will do this, or do I need to use a totally different script. Here is what's in the head of the pop-up page:

    var isNav4, isIE4;
    if (parseInt(navigator.appVersion.charAt(0)) >= 4) {
    isNav4 = (navigator.appName == "Netscape") ? 1 : 0;
    isIE4 = (navigator.appName.indexOf("Microsoft") != -1) ? 1 : 0;
    }
    function fitWindowSize() {
    if (isNav4) {
    window.innerWidth = document.layers[0].document.images[0].width;
    window.innerHeight = document.layers[0].document.images[0].height;
    }
    if (isIE4) {
    window.resizeTo(600,600);
    width = 600 - (document.body.clientWidth - document.images[0].width);
    height = 600 - (document.body.clientHeight - document.images[0].height);
    window.resizeTo(width, height);
    }
    }

    And the body tag gets the "onload="fitWindowSize()".

    Any suggestions would be appreciated.
    "It takes a big man to cry, but it takes a bigger man to laugh at that man." Jack Handy

  • #2
    what's the code your using to open the window?

    Are you doing a window.open or target="_blank" in the href?

    Comment


    • #3
      target="_blank"
      "It takes a big man to cry, but it takes a bigger man to laugh at that man." Jack Handy

      Comment


      • #4
        well if you are using _blank you cant do much i think but with window.open try this

        winodw.open("page.html", "pagename", "menubar=0, toolbar=0, statusbar=0, personalbar=0") there are few more but i cant remeber them
        photoshop too expensive? use the GIMP! www.gimp.org

        Comment


        • #5
          Don't mean to be a nuisance...

          but I'm going to try to learn something while I'm at this forum (since I'm at a standstill with my project, everybody's left, and I'm the only one at the office).

          Does the code that you suggest, whackaxe, make like those annoying add pop-up windows that you get and that you can't find the [X] button at the top right of the window?

          And where can I find all the properties of all these parts of a webpage? When I read over other people's JavaScript code and such, all these properties just seem to pop out of nowhere. It certainly would be good if there's a reference I could look at with all these properties listed.
          -Obiwan Jabroni
          May the Schwartz be With You

          Comment


          • #6
            no it makes whatever type of window you choose with the different parameters

            go down the folder tree in this order in the msdn.microsoft.com/library section and look for open(window) and look at all the different thigs it does

            web development > HTML and Dynamic HTML > Reference > Methods
            photoshop too expensive? use the GIMP! www.gimp.org

            Comment

            Working...
            X