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 6 of 6
  1. #1
    Regular Coder
    Join Date
    Jun 2002
    Posts
    271
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Modifying the Window

    I have this script I use

    <form action=http://www.url.net/cgi-bin/mail/subscriber.cgi method="post" target="_new">

    Is there a way to set the size of the "_new" window ??

  • #2
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,676
    Thanks
    6
    Thanked 1,008 Times in 981 Posts
    Actually you would use target="_blank" to open a new window but those methods are deprecated altogether. To open a new window and set its size you would use JavaScript. But be aware that people can switch that off in part or entirely (I, for example, have enabled JS but switched off any possibility for scripts to change my window size and/or statusbar content).

    Code:
    <form … onsubmit="window.open('URL','height=100,width=200')">
    …
    http://www.w3schools.com/htmldom/met_win_open.asp
    Last edited by VIPStephan; 10-22-2007 at 07:25 PM.

  • #3
    Regular Coder
    Join Date
    Jun 2002
    Posts
    271
    Thanks
    4
    Thanked 0 Times in 0 Posts
    That does not work It stills opens in a full window I think do to it being a form that does not work??

    Can you post the complete link i need to use as maybe I am doing it wrong

    THXS Steve

  • #4
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,676
    Thanks
    6
    Thanked 1,008 Times in 981 Posts
    Sorry, forgot the window name…
    Code:
    <form action="" method="get" onsubmit="window.open('http://google.com','windowname','height=100,width=200');">
    You can leave the window name value out but you need to include the quotes.

  • #5
    Regular Coder
    Join Date
    Jun 2002
    Posts
    271
    Thanks
    4
    Thanked 0 Times in 0 Posts
    That brings up the signup box

    Please go to http://www.cruisevacationcenter.net/mail.html

    Just hit send and watches what happens

    I think this can not be done BUT maybe


    Steve

  • #6
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,676
    Thanks
    6
    Thanked 1,008 Times in 981 Posts
    I don’t see the code implemented that I proposed above? And if I add it using my web developer toolbar it does exactly what you want.

    Edit: Ah, hang on… you want to display the error message if someone is leaving out the address? That would be different then… hang on, need to try it myself.
    Last edited by VIPStephan; 10-22-2007 at 08:35 PM.


  •  

    Posting Permissions

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