#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2003
    Posts
    53
    Rep Power
    11

    Javascript codes for controlling window sizes


    Hello,
    Sorry it's me again.
    Can someone please teach me how to use javascript to control various pop up windows?

    Example:

    index.htm has 3 links.

    link 1 pops up Products.htm, size 400x300, no scroll bars etc
    link 2 pops up Contact.htm, size 300x150, no scroll bars etc
    link 3 pops up About us.htm, size 450x500, no scroll bars etc

    Taking the above example what code is needed for it to work?
    Do i just need the script in the index.htm page?

    Tahnks again.
  2. #2
  3. Contributing User
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Oct 2001
    Location
    New Zealand
    Posts
    1,774
    Rep Power
    24
    To open another window you can simply put it in the link:

    <a href='#' onClick='window.open("Products.htm","","width=400, height=300")'>
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2003
    Posts
    53
    Rep Power
    11
    ah cheers, what about the scroll bars? can i get rid of them?

IMN logo majestic logo threadwatch logo seochat tools logo