We Recommend

Pro JavaScript Techniques Pro JavaScript Techniques
Pro JavaScript Techniques is the ultimate JavaScript book for the modern web developer. It provides everything you need to know about modern JavaScript, and shows what JavaScript can do for your web sites. This book doesn't waste any time looking at things you already know, like basic syntax and structures.


Posted By

Feb30th1712 on 01/13/08


Tagged

resize window bookmarklet viewport


Versions (?)


Who likes this?

1 person has marked this snippet as a favorite

korzhik


640xMAX


Published in: JavaScript 


A bookmark-let that resizes the width of the view-port to 640 and the height of the window to the height of the screen excluding the task-bar. Then move the window to the left top corner.

  1. /*
  2. javascript:moveTo(0,0);var width,height;width=outerWidth-innerWidth+640;height=screen.availHeight;resizeTo(width,height);
  3. */
  4. moveTo(0, 0);
  5. var width, height;
  6. width = outerWidth - innerWidth + 640;
  7. height = screen.availHeight;
  8. resizeTo(width, height);

Report this snippet 

You need to login to post a comment.