popup window not working

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
James M.
Forum Contributor
Posts: 119
Joined: Wed Mar 31, 2004 6:41 pm
Location: Tallahassee

popup window not working

Post by James M. »

Hi, I'm just now learning javascript (after finding out that it's useful in saving bandwidth) and I was just testing this function to make a popup window but it doesnt seem to be working, and i have this other line of code [ window.status="some text"; ] that will only work when the function is not active.

heres the function by the way:

Code: Select all

function popup()
{
          testwindow=window.open
          ("url", "name","status=1, toolbar=1,
          width=300, height=200");
          testwindow.moveto(100,100);
}
and i use <a href="javascript: popup()"></a> to call it. thanks for any help ahead of time.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

is that the real code?
User avatar
James M.
Forum Contributor
Posts: 119
Joined: Wed Mar 31, 2004 6:41 pm
Location: Tallahassee

Post by James M. »

well there is actaully a url and a name, its my first javascript function.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

could you post that.. those (esp the name, can be crucial in solving a problem with window.open
User avatar
James M.
Forum Contributor
Posts: 119
Joined: Wed Mar 31, 2004 6:41 pm
Location: Tallahassee

Post by James M. »

Code: Select all

function login()
      &#123;
          testwindow=window.open ("http://localhost/project2/test.php", "join","status=yes, toolbar=yes,
          width=300, height=200");
          testwindow.moveto(0, 0);
      &#125;
Post Reply