Created
November 30, 2008 22:54
-
-
Save tobi/30546 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?PHP | |
function compute_key_for_src($src) { | |
// Replace with your API key | |
return md5('<YOUR API KEY>'.$src) | |
} | |
function screenshot_of($src) { | |
// Replace with the url to the profile that will take the screenshot | |
return 'http://www.web2png.com/s/123/frontpage.png?src=$src&key='. compute_key_for_src($src); | |
} | |
?> | |
<img src="<?PHP echo(screenshot_of('http://www.cnn.com')) ?>" width="" height="" /> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment