Page 1 of 1

URL snapshot

Posted: Sat Oct 25, 2008 3:16 pm
by ddragas
Hi all
Does somebody know a class to take image (jpeg) snapshot from URL written all in php and without third part software.

Thank you all

Kind regards

Re: URL snapshot

Posted: Sat Oct 25, 2008 9:26 pm
by josh
PHP itself is made up of 3rd party software.

I suppose you could write a DOM parser and build a look alike snapshot with GD,

or you could just make a command line call to a web browser and then read the jpeg into PHP ;-)

The thing is is a webpage is just text. Browsers render a graphical representation, the OS already has hooks in place for grabbing the screen from the browser. PHP on the other hand runs on the command line, so you you're really asking about apples and oranges here

Re: URL snapshot

Posted: Sun Oct 26, 2008 2:28 am
by ddragas
thank you for reply.
I understand. One more question. My client has VPS in command line linux server (Ubuntu) and there is no GUI.
How can web browser be used with this? Is it possible?

Re: URL snapshot

Posted: Sun Oct 26, 2008 2:56 am
by josh
If you install firefox, it should have command line options for doing what you need to do, you could have PHP send the command to firefox while redirecting the snapshot output to a file then read the file from PHP, manipulate it, and do whatever

Re: URL snapshot

Posted: Sun Oct 26, 2008 2:59 am
by ddragas
thank you for your help

kind regards