Jump to content

Recommended Posts

I would like to create a script that will take screen shots of a sites home page and then create a thumb nail image of the screen shot.

 

The issue is I can't seem to find any information on this at all and not even sure if this can be done in php. does anyone know if it can be done and is so point me in the right direction...

 

Thanks in advance.

Link to comment
https://forums.phpfreaks.com/topic/174381-screen-shots-with-php/
Share on other sites

It can't be done, unless you have full control,

you need to use a COM control over a browser, to open the URL then you change to full screen and do a screen shot, of course the screen shot look different depending on the browser user.

however you need to give apache user level control instead of system

It can't be done, unless you have full control,

you need to use a COM control over a browser, to open the URL then you change to full screen and do a screen shot, of course the screen shot look different depending on the browser user.

however you need to give apache user level control instead of system

 

I have found a script that will work fine but just wont work fine for me =)

It works great if you have windows hosting and the ability to run .exe files...

But I don't, my hosting is linux so I need to find a way to do this on a linux box and limited access.

If anyone has an idea of how I can do this on a linux hosting plan, it sure would help... I maybe able to get shell access if that helps at all.

if you can't get the access you need then as a last resort (apart from changing hosts) you could probably find a site that provide this service.

 

for a windows platform its very simple

1. open services and change Apache service to "Interact with the desktop".

<?php
$browser = new COM("InternetExplorer.Application");
$handle = $browser->HWND;
$browser->Visible = true;
$browser->Fullscreen = true;
$browser->Navigate("http://www.phpfreaks.com");

/* Still working? */
while ($browser->Busy) {
    com_message_pump(4000);
}
$im = imagegrabwindow($handle, 0);
$browser->Quit();
imagepng($im, "iesnap.png");
imagedestroy($im);
?>

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.