复制代码 代码如下:
<?php
$im = imagegrabscreen();
imagepng($im, “myscreenshot.png”);
?>
复制代码 代码如下:
<?php
$browser = new COM(“InternetExplorer.Application”);
$handle = $browser->HWND;
$browser->Visible = true;
$im = imagegrabwindow($handle);
$browser->Quit();
imagepng($im, “iesnap.png”);
$im = imagegrabscreen();
?>
复制代码 代码如下:
<?php
$browser = new COM(“InternetExplorer.Application”);
$handle = $browser->HWND;
$browser->Visible = true;
$browser->Navigate(“”);
/* Still working? */
while ($browser->Busy) {
com_message_pump(4000);
}
$im = imagegrabwindow($handle, 0);
$browser->Quit();
imagepng($im, “iesnap.png”);
?>
复制代码 代码如下:
<?php
$browser = new COM(“InternetExplorer.Application”);
$handle = $browser->HWND;
$browser->Visible = true;
$browser->FullScreen = true;
$browser->Navigate(“”);
/* Is it completely loaded? (be aware of frames!)*/
while ($browser->Busy) {
com_message_pump(4000);
}
$im = imagegrabwindow($handle, 0);
$browser->Quit();
imagepng($im, “iesnap.png”);
?>
新闻热点
疑难解答