img = new Image();
img.src = 'process.php?height=' + screen.height + '&width=' + screen.width;
img = undefined;
The main difference from the above solution is that the PHP script then runs completely independently of the current page which stays visible. The only other requirement is that the PHP be set to create a dummy image.
for an example use where it regularly tells the server that the page is still open.
Helping others to solve their computer problem at http://www.felgall.com/