SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Thread: Link checker

  1. #1
    SitePoint Enthusiast
    Join Date
    Sep 2004
    Location
    Belguim
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Link checker

    I have a gamesite: http://placex.be & I want to check if the games are still available. Does somebody know how to make a linkchecker to check if the page/game still exists?

    Thanks,
    Joris

  2. #2
    Umm. PHP Guru....Naaaah jaswinder_rana's Avatar
    Join Date
    Jul 2004
    Location
    canada
    Posts
    3,193
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    you can try using this function
    PHP Code:
        function checkLink($url)
        {
            
    error_reporting(0);
            
    $fh fopen($url,'r');
            
    error_reporting(E_ALL);
            return (
    $fh)?1:0;
        }
            
    $link 'http://yourwebsite.com';
            if(
    checkLink($link))
               echo 
    'Link exists.';
            else
               echo 
    'Link does not exist.'
    there might be other advanced methods which i am not aware off
    ---------------------------
    Errors = Improved Programming.
    My Site

  3. #3
    SitePoint Addict SRTech's Avatar
    Join Date
    Mar 2005
    Posts
    224
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The W3C has a free online checker that might work for you:
    http://validator.w3.org/checklink


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •