shage Posted July 24, 2007 Share Posted July 24, 2007 Im looking for a way to grab a random image from a gallery that links to a bigger image, just one thou, and add the http to a db, that way on call of a tutorial site it can grab the image and post it, but really im looking for the way to just search a page i say, add a random image that links to a bigger image in the db. thank you Link to comment https://forums.phpfreaks.com/topic/61624-grab/ Share on other sites More sharing options...
trq Posted July 24, 2007 Share Posted July 24, 2007 Sorry, you'll need to be more specific. For starters, is this image on your server or somewhere else? Link to comment https://forums.phpfreaks.com/topic/61624-grab/#findComment-306739 Share on other sites More sharing options...
shage Posted July 24, 2007 Author Share Posted July 24, 2007 somewhere else is where the image is, im looking at having title,description and image location in database, so it would call teh whole url so a hotlink as its a tutorial site. Link to comment https://forums.phpfreaks.com/topic/61624-grab/#findComment-306744 Share on other sites More sharing options...
trq Posted July 24, 2007 Share Posted July 24, 2007 Screen scraping then. You'll need to look at file_get_contents to get the page content and then url=http://php.net/preg_match]preg_match[/url] to parse it for the images you want. Link to comment https://forums.phpfreaks.com/topic/61624-grab/#findComment-306748 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.