Get Remote Page Title |
[eluser]Dregond Rahl[/eluser]
Does this method seem effective? Anything I can do to improve it? I only need the title. Code: function _get_page_title($url)
[eluser]Wuushu[/eluser]
Hi, if you're going to use the data for display, it's always best practice to save the data to file/db/whatever so that on second+ lookups, you will not have to hit whoever's server it is that you're hitting - again. Just my 0.02
[eluser]Dregond Rahl[/eluser]
Yeah its stored in a database, this is just the getting function =]
[eluser]OES[/eluser]
Hi Not sure if you still need this but I just posted on my blog a helper for Screen Scrapping. Would make your code alot less thanks to simple html dom :-). Check it out.
[eluser]Dregond Rahl[/eluser]
[quote author="OES" date="1245303409"]Hi Not sure if you still need this but I just posted on my blog a helper for Screen Scrapping. Would make your code alot less thanks to simple html dom :-). Check it out.[/quote] Thanks for this =], the reason why i used cURL was because my test sever is shared so it doesn't support URL file access, does Simple HTML DOM work still ? Thanks, this might be useful for when i move to my real server.
[eluser]cahva[/eluser]
Funny that they let you use curl but not URL file access. Curl extension has had more holes than a swiz-cheese Forbidding url access with include,require etc. is perfectly understandable but when using file_get_contents, fopen etc. it really is not necessary.
|
Welcome Guest, Not a member yet? Register Sign In |