|
|
 |
Re: FN-FORUM: SEO and links check
date posted 21st May 2007 10:04
> Thanks for that but this is a link exchange program, so it is links from a
> site which has had a link submitted that I want to be able to check 'live'
> as it were.
I'm still a bit unsure of what your trying to do... Do you want a link that
when you click it will tell you if a certain site is available. This
probably is do-able but there are other things you need to consider for
example what if the client has put up an 'under construction' page. The link
will find a page at the site however the site isn't truly live. This may not
matter for you however i think it would be much easier to just have a link
to the site that opens in a seperate window so that the user can see the
content of the site.
If you insist on doing it your way a good way to check that their server is
online/domain name is mapped to a server would be to ping the host. Theres a
link to an article for doing this in PHP below.
http://builder.com.com/5100-6371-5234592.html
Also if theres a way of using request objects on remote sites in AJAX you
could send a request to the web server and if nothing is returned then
theres no page, however i think AJAX requests only work on the same domain
for security reasons.
James
|
 |
|