Opening web app in a new window after login. how?

Hey all. i m working on a web app. i want after login button the web app is opened in a popup (1280, 800). i never used JS before so i have no idea how to do it but i need help with it. wht shld i do?

http://www.javascript-coder.com/window-popup/javascript-window-open.phtml

thanks dan for the link. however i need to know how can i implement it when someone click submit button coz that when i want it. after someone click submit.

Don’t you need to process the login form before you can pop up the application, not just pop it up upon clicking the submit button? Or did you want the login details to get sent to the page in the window you open?

the later one i want.

i want opup to be created after the password/login has been authorized

anyone help me!!

Your posts are contradictory. Formulate a very clear problem statement and maybe someone will give it a try.

i just want very simple JS. i want that when a person click on a button the whole CMS is open in a new window which has a with of 1280 * 800. thats it

<input type="button" value="Open Window" onclick="window.open('http://www.example.com','popup','width=1280,height=800')" />

i am unable to pop it up. it opens it the same window. :frowning: here is the code

<body onLoad="checkLogin();">
                            <table width="100" align="center">
                            <tr>
                            <td>
                                <div id="login">
                                        <div id="loginbox">
                                        <form action="login_proc.php" method="post" name="form1"id="form1">
                                          <table width="400" border="0" cellspacing="0" cellpadding="0">
                                            <tr>
                                              <td width="50">Username</td>
                                              <td width="50"><input name="txtUsername" type="text"id="txtUsername" style="margin:5px;"/></td>
                                            </tr>
                                            <tr>
                                              <td>Password</td>
                                              <td><input name="txtPassword" type="password"id="txtPassword" style="margin:5px;"/></td>
                                            </tr>
                                            <tr>
                                              <td colspan="2" align="left"><table width="400" border="0" cellspacing="0" cellpadding="0">
                                                <tr>
                                                  <td width="140">&nbsp;</td>
                                                  <td><table width="70" border="0" cellspacing="0" cellpadding="0">
                                                    <tr>
                                                      <td height="35" align="center"><input class="loginbutton" value="Login" type="submit"></td>
                                                    </tr>
                                                  </table></td>
                                                </tr>
                                              </table></td>
                                            </tr>
                                          </table>
                                          </form>
                                        </div>

     
                
                
                </div>          
</td>
</tr>
</table>
</body>

thats the code without the popup JS/ wht shld i do?

hey folks, i have created this function, but there r issues.

  • In IE the width and height isn’t the what i gave it.
  • In FF i think JS attributes like statusbar=no etc is ignored how do i make it implement of FF too?

<script type="text/javascript">
function Resize()
{
    window.open("home.php","_blank","toolbar=no","location=yes","directories=no","status=no","menubar=no","scrollbars=no","resizeable=no","copyhistory=yes, width=1280, height=800");
}
</script>

window.open only takes 3 parameters

the 3rd parameter is a list

It should look like “toolbar=no,location=yes” not “toolbar=no”,“location=yes”

what about the IE issue. why doesn’t it follow the width and height i gave it?

Perhaps it will help if you show us the width and height?

1280 * 800

I should have been clearer.

It will help if you show us the scripting code that you are using to open the window at a certain size.

It actually takes 4 parameters. The fourth one has to do with the history when reusing existing windows and is only ever true or false. Unless a window with the name in the second parameter already exists the fourth parameter is ignored (the same as the third parameter is ignored if it does exist - and quite often even if it doesn’t).

those values are optional. The browser doesn’t have to follow them if the window already exists or you are opening in a new tab or if the size is too big to fit on the screen or if it is below the minimum size or if the browser owner tells the browser to ignore the size.

It might actually be following the size you specified and you forgot to allow for the size of the menubar, toolbars, statusbar, addressbar etc that the new window iis displaying (some of which are mandatory in modern browsers).

Here is the code which i m using. about parameters i haven’t started working on that as i looked in w3school JS.