Checking if a site is available

This is a discussion on Checking if a site is available within the PHP Language forums, part of the PHP Programming Forums category; What PHP code would I use to check if submitted sites to my directory actually exist?? I want to use ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-29-2003
John Ryan
 
Posts: n/a
Default Checking if a site is available

What PHP code would I use to check if submitted sites to my directory
actually exist?? I want to use something that can return the server
code to me, ie HTTP 300 OK, or whatever. Can I do this with sockets??
Reply With Quote
  #2 (permalink)  
Old 06-29-2003
Jason Dumler
 
Posts: n/a
Default Re: Checking if a site is available

John,

Probably the curl library would be a LOT easier to work with. There's
probably an example of what you are talking about in the documentation
at php.net. Even shelling out to the curl binary would be easier than
re-writing the http protocol to see if sites are up.

Jason

John Ryan wrote:
> What PHP code would I use to check if submitted sites to my directory
> actually exist?? I want to use something that can return the server
> code to me, ie HTTP 300 OK, or whatever. Can I do this with sockets??


Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 10:12 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0