FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Fetching an external web page
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Fetching an external web page [message #171333 is a reply to message #171296] Thu, 30 December 2010 13:08 Go to previous messageGo to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 12/29/2010 10:35 PM, richard wrote:
> On Wed, 29 Dec 2010 13:08:35 -0800 (PST), Captain Paralytic wrote:
>
>> On Dec 29, 7:09 pm, Mike<mpea...@gmail.com> wrote:
>>> I want to grab a web page, it's response headers and parse the whole
>>> thing. So, I want the response headers, meta tags, and some of the
>>> content extracted. The way I'm doing it now takes three calls to the
>>> remote server. How can I do it with just one call?
>>>
>>> Here's my current code:
>>>
>>> $htmlSource = file_get_contents($this->url);
>>> $responseHeaders = get_headers($url, 1); // Possible to combine with
>>> get_contents?
>>> $metaTags = get_meta_tags($url); // How could I use this with
>>> $htmlSource?
>>>
>>> Thanks for the help!
>>>
>>> Mike
>>
>> use curl (and it's "its" not "it's")
>
> See what I mean? Bashed for a minor spelling mistake.

Get over it, Richard. Paul has corrected me on the very same mistake
and I know better. But I didn't take it personally.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Failed to write to a text file (text file is RW)
Next Topic: PHP Bug + Hotfix
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Oct 04 23:21:22 GMT 2024

Total time taken to generate the page: 0.04770 seconds