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 7 of 7
  1. #1
    New to the CF scene
    Join Date
    Jun 2002
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Macintosh Control position and size of primary window

    Hi,

    I have searched many places trying to find a script that allows me to center and specify the size of the primary window when someone enters the website. I have checked almost everywhere and found scripts that only allow you to control a secondary window. I would like my website to position itself in the center of the user's screen and only be the size that i specify. Can anyone help me out?

    Thanks in advance

    M

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Posts
    676
    Thanks
    1
    Thanked 0 Times in 0 Posts
    web...
    /me seems to think it can onlyyy be controlled/positioned ifin' its just a window® YOUUU opened...aka secondary...:O((( sooo thattts why you probably just a cant® find some 'script' to do it for you...:O(((
    The New JustaBuster Version 2.0 OR JustaBusta Lite V2.0
    ...just a special® thanx kinda hugs to jkd n' nex ...:O)))

    CommemorateWTC.com --Please lend your support

  • #3
    Regular Coder
    Join Date
    Jun 2002
    Location
    The Planet Earth Code Poet: True
    Posts
    282
    Thanks
    0
    Thanked 1 Time in 1 Post
    You can specify the size and the position of the primary window:

    <script type="text/javascript">

    window.resizeTo(x,y) //where x=width in pixels and y=height in pixels
    window.moveTo(l,t) //where l=left position in pixels and t=top position in pixels

    </script>

  • #4
    Regular Coder
    Join Date
    Jun 2002
    Posts
    676
    Thanks
    1
    Thanked 0 Times in 0 Posts
    john...
    /me thought just a bout® that 'onload' script...
    'cept then??? its nottt the window reallly that the viewer first just a sees® when they typein/goto www.domain.com

    just a great® way to get just a round® using 'itself' to resize/position...vs /me was thinking of opening just a second® one...

    just a nother® reason yourrre the mod n' /me still isnt just a programmed® to think...hehehe...
    The New JustaBuster Version 2.0 OR JustaBusta Lite V2.0
    ...just a special® thanx kinda hugs to jkd n' nex ...:O)))

    CommemorateWTC.com --Please lend your support

  • #5
    New to the CF scene
    Join Date
    Jun 2002
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thank you for the help.

    I put the following code into my page and received and error stating that x was not defined:

    <script type="text/javascript">

    window.resizeTo(x,y) //where x="801" and y="324"
    window.moveTo(l,t) //where l="300" and t="350"
    </script>


    What am I doing wrong?

  • #6
    Regular Coder
    Join Date
    Jun 2002
    Location
    The Planet Earth Code Poet: True
    Posts
    282
    Thanks
    0
    Thanked 1 Time in 1 Post
    Those where just comments to instuct you what to put there. You would do it like this:

    <script type="text/javascript">
    window.resizeTo(801,324);
    window.moveTo(300,350);
    </script>

    or like this:

    <script type="text/javascript">
    x=801;
    y=324;
    l=300;
    t=350;
    window.resizeTo(x,y);
    window.moveTo(l,t);
    </script>

  • #7
    Regular Coder
    Join Date
    Jun 2002
    Location
    Adelaide, South Australia
    Posts
    150
    Thanks
    0
    Thanked 0 Times in 0 Posts
    G'day Web..

    I came across this earlier today and, in all honesty didnt understand the use on first thoughts, but I dragged it out of 'History' when I saw your question. If its not what youre after, please excuse the downunder newbie.. Just trying to be helpful... (and also live up to my tag LOL)

    http://www.fo3nix.pwp.blueyonder.co....enteralleg.htm

    reached from:

    http://www.fo3nix.pwp.blueyonder.co.uk/scripts.htm

    Cheers!
    KB...
    To escape criticism - do nothing, say nothing, be nothing. . . Vaya Con Dios


  •  

    Posting Permissions

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