SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Member
    Join Date
    Jun 2000
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm sure this is as easy as pie, but I can't find how to make a new window a certain size. What I want is have a link open a new window that is 200x100 size. Anybody care to help me out?

    ------------------
    J Andersen

  2. #2
    Your Lord and Master, Foamy gold trophy Hierophant's Avatar
    Join Date
    Aug 1999
    Location
    Lancaster, Ca. USA
    Posts
    12,305
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Try this

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">code/font><HR><pre>
    &lt;a href="javascript:window.open('file2open.html','PopUp', 'toolbar=no,status=no,width=200,height=100');"&gt;
    [/code]



    ------------------
    Wayne Luke - Sitepoint Moderator/Internet Media Developer
    Digital Magician Studios - Making Magic with Web Applications
    wluke@digitalmagician.com

  3. #3
    SitePoint Member
    Join Date
    Jun 2000
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hmm... That works good for the pop-up part, but when you click the link, it opens the pop-up window and also directs the original browser to the javascript code.

    I don't know how to explain it clearly, so I also took a screenshot of it.
    jspopup.jpg

  4. #4
    SitePoint Member
    Join Date
    Jun 2000
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nevermind, I got it working. Here's the fixed version.

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">code/font><HR><pre>&lt;a href="#" onClick="window.open('file2open.html','PopUp','toolbar=no,status=no,width=200,height=100')"&gt;[/code]

    Thanks for your help! I appreciate it.

  5. #5
    SitePoint Zealot Lars's Avatar
    Join Date
    Jun 2000
    Location
    Denmark
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you want scroll bars then put this coding in: ,scrollbars=yes

  6. #6
    SitePoint Member
    Join Date
    Jun 2000
    Location
    Brossard
    Posts
    8
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote/font><HR>Originally posted by J_Andersen:
    I'm sure this is as easy as pie, but I can't find how to make a new window a certain size. What I want is have a link open a new window that is 200x100 size. Anybody care to help me out?

    <HR></BLOCKQUOTE>

    Read the tutorials about this at: http://www.visicommedia.com/community/



    ------------------
    Dominic Tremblay
    AceHTML 4 Freeware
    http://www.visicommedia.com

  7. #7
    Jules
    SitePoint Community Guest
    This is all very well but for the icing on the cake can anyone tell me me how to control where our new window pops up on the users moniter?


    ...Nevermind! I just discovered you can specify distance from top and left eg:
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">code/font><HR><pre>"toolbar=no,menubar=no,location=no,scrollbars=no,width=450,height=100,top=600,left=400,resize=no"[/code]

    [This message has been edited by Jules (edited June 29, 2000).]


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
  •