Jump to content

Extract Text from page


fraser5002

Recommended Posts

Hi All,

 

Bit of a strange one but i would like to be able to supply a URL to a page.

 

This page will always contain an image and the copyright that goes with it for example

 

http://www.geograph.org.uk/photo/693325

 

The copyright lies undearneath

 

I would like to get some php code that would automatically grab the image and copy this to a directory on mt site and also take the creative commons copyright notice as a string ( which i will then display along side the image when i add it to  my site)

 

How can i do this through php

 

I know that the word "copyright" only ever appears once on the page ( as part of the bit im trying to grab) so can i use this somehow to grab the whole string?

 

 

Basically im being lazy and would like to automate the process of grabbing the image and copywrite without having to download it to my computer first and reload to my server ( as i will be doing this quite a lot)

 

Any ideas much appreciated

Thanks

 

Link to comment
https://forums.phpfreaks.com/topic/232757-extract-text-from-page/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.