Skip to content

eyecatchup/php-site-screenshot

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

PHP-Site-Screenshot

This will take a screenshot of a given site url and save it to the desired output path.

But first, you need cutycapt and xvfb as this script relies on a headless webkit to take the screenshot: https://github.com/jaequery/cutycapt-installer-script-on-ubuntu

Second, you need to configure this script:

// lib path
$xvfb_path = '/usr/bin';
$cutycapt_path = "/home/user/scripts/cutycapt/CutyCapt";

// capture settings
$screen = '1280x1024x24';
$output_path = '/home/user/www/images/capture.png';
$url = $_GET['url']; // set it however you want
//$url = 'http://www.yahoo.com'; // set it manually

Change them accordingly.

To get you started, here is a simple usage: http://localhost/capture.php?url=http://www.google.com

About

take a screenshot of any webpages using PHP w/ Cutycapt

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published