unenergizer Posted March 20, 2006 Share Posted March 20, 2006 Are there any know tutorials about how to take snap shots of websites with php? Im not excatly sure how to describe this, but I found a perfect example. At www.whois.sc, when I searched for my domain, just out of bordom, I saw that it showed the homepage of my site (http://www.whois.sc/gamehaxs.com). I was just wondering how to do this. If you can help me find a tutorial or more reading on this, then I would GREATLY apperciate it! Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/ Share on other sites More sharing options...
micah1701 Posted March 20, 2006 Share Posted March 20, 2006 I too am amazed by the autogenerated screen shots that I've seen recently all over the web.I know a lot them come from www.thumbshots.orgthere is some good info there - and they have a free service to integrate into your site. But they dont reveal the magic. Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19140 Share on other sites More sharing options...
jvalarta Posted March 20, 2006 Share Posted March 20, 2006 Agreed. Alexa.com also seems to have something in place, though I've been unable to figure out the technology behind this. Anyone? Anyone? Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19167 Share on other sites More sharing options...
JustinK101 Posted March 20, 2006 Share Posted March 20, 2006 Humm the only thing I can think of is they invoke the php GD image libary. Then just get each pixel at a page and create an image by this built up maxtrix of pixels. I could be wayyy off here. Interested if anybody acutally knows. ;) Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19175 Share on other sites More sharing options...
redbullmarky Posted March 21, 2006 Share Posted March 21, 2006 [!--quoteo(post=356800:date=Mar 20 2006, 11:52 PM:name=JustinK101)--][div class=\'quotetop\']QUOTE(JustinK101 @ Mar 20 2006, 11:52 PM) [snapback]356800[/snapback][/div][div class=\'quotemain\'][!--quotec--]Humm the only thing I can think of is they invoke the php GD image libary. Then just get each pixel at a page and create an image by this built up maxtrix of pixels. I could be wayyy off here. Interested if anybody acutally knows. ;)[/quote]i can only personally think of a handful of possible ways- manually. ok, so whilst alexa deals with millions of sites, if you've ever tried to change your contact details or related links, you'll notice that they state that the submissions get moderated and checked, etc, before going live.- custom browser parser. so just like IE/FF takes a page and decides to stick it in a big full screen window, and cross-browser element sizes can depend on each browser, it could be possible to get the html from a page and render it in a particular way, before 'setting' it with a snapshot. i have managed to 're-parse' parts of a page before, but how they would go about doing it i do not know.definitely an interesting one, but my bet (at least for alexa) is that the first one is more likely. Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19182 Share on other sites More sharing options...
DD32 Posted March 21, 2006 Share Posted March 21, 2006 I Think some people have modified mozilla slightly to allow them to take a snapshot of what you would see..Mozilla would've been chozen simply because its open souce....-=DD32=- Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19194 Share on other sites More sharing options...
.-INSANE-. Posted March 21, 2006 Share Posted March 21, 2006 [!--quoteo(post=356819:date=Mar 20 2006, 06:49 PM:name=DD32)--][div class=\'quotetop\']QUOTE(DD32 @ Mar 20 2006, 06:49 PM) [snapback]356819[/snapback][/div][div class=\'quotemain\'][!--quotec--]I Think some people have modified mozilla slightly to allow them to take a snapshot of what you would see..Mozilla would've been chozen simply because its open souce....-=DD32=-[/quote]this seems the most likely i kno sum people that kno how to tweak firefox Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19216 Share on other sites More sharing options...
redbullmarky Posted March 21, 2006 Share Posted March 21, 2006 actually this maybe right also. i just remember i have a plugin on firefox called 'Reveal' which, when you hover over the browsers back or forward button, shows a thumbnail preview. size of the thumbnail can be adjusted, etc. Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19263 Share on other sites More sharing options...
unenergizer Posted March 21, 2006 Author Share Posted March 21, 2006 This process for me would have to be automated. Taking manual screenshots is not an option. I have come to realize that this may be an asp application, or could even be a cgi application aswell. However, php is not a requirement for me with my project in plan, so if anyone knows about being able to do this with any server side scripting languages, then please share. :)Thanksunenergizer Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19376 Share on other sites More sharing options...
redarrow Posted March 21, 2006 Share Posted March 21, 2006 [!--quoteo(post=357003:date=Mar 21 2006, 04:30 PM:name=unenergizer)--][div class=\'quotetop\']QUOTE(unenergizer @ Mar 21 2006, 04:30 PM) [snapback]357003[/snapback][/div][div class=\'quotemain\'][!--quotec--]This process for me would have to be automated. Taking manual screenshots is not an option. I have come to realize that this may be an asp application, or could even be a cgi application aswell. However, php is not a requirement for me with my project in plan, so if anyone knows about being able to do this with any server side scripting languages, then please share. :)Thanksunenergizer[/quote]I found it its a class in php[a href=\"http://www.phpclasses.org/browse/package/918.html\" target=\"_blank\"]http://www.phpclasses.org/browse/package/918.html[/a] Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19451 Share on other sites More sharing options...
litebearer Posted March 22, 2006 Share Posted March 22, 2006 A couple of other possibilities are here...[a href=\"http://redux.imagemagick.org/discussion-server/viewtopic.php?t=5973&sid=10a67d3fbc01ace3312bec56b1217431\" target=\"_blank\"]http://redux.imagemagick.org/discussion-se...12bec56b1217431[/a]Lite... Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19527 Share on other sites More sharing options...
brokenhope Posted March 23, 2006 Share Posted March 23, 2006 Well, I just thought I would give some input on how you would go about doing this with PHP and GD.You would need to get your script to parse the tables, and "redraw" everything correctly, using GD, add in images, backgrounds done by loops by figuring the sizes of the original and repeating, quite a lot of work, but could be done... probably would require a lot of power to do to. Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19836 Share on other sites More sharing options...
unenergizer Posted March 23, 2006 Author Share Posted March 23, 2006 This seems to be beyond the scope of my programming knowledge. I really want to get started in programing php, but as of now all I have are online tutorials to read. Though I do have some experience, I just dont have enough for this. Though, can anyone reccommend a great resource that explains GD, that maybe even will provide tutorials, etc.Thanksunenergizer Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19968 Share on other sites More sharing options...
redbullmarky Posted March 23, 2006 Share Posted March 23, 2006 the best place (and this is not fobbing you off) is the php manual. if the in-depth descriptions of the individual functions don't help, then the examples and the user comments definitely will. start here: [a href=\"http://www.php.net/imagecreate\" target=\"_blank\"]http://www.php.net/imagecreate[/a]once you get used to GD, it's really not all that hard. but as for hoping that GD will be the solution to your 'snapshot' problem, i very much doubt it. going to the trouble of parsing a webpage's code, images, etc - you may as well totally write your own browser for all the work it'll take you.CheersMark Quote Link to comment https://forums.phpfreaks.com/topic/5354-taking-snap-shots-in-php/#findComment-19976 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.