Jump to content

Search the Community

Showing results for tags 'get_headers'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 1 result

  1. <html><center><br><br><br>checks with get headers <form action="#" method="post"> <input type="text" name="webadres" value=" " required> <br> <input type="submit" value="Send" ><br><br><br> </form> <?php if ($_SERVER['REQUEST_METHOD'] == 'POST'){ $sites= $_POST['webadres']; var_dump($sites); if (isset($sites)) { var_dump(get_headers($sites)); } ?> <br><br>Checks with curl get info <?php $url = curl_init($sites); curl_setopt($url, CURLOPT_RETURNTRANSFER, 1); $result = curl_exec($url); $info = curl_getinfo($url); print_r($info); curl_close($url); } ?> </html> I made above script to test whether a webadress exists or not. I'm very surprised that a lot of inputs dont give any result, they actually give a php error message. using sites like http://www.facebook.com does not work, for it twitter it runs. pinterest does only run http and not https. I also found sites like http://www.bbc.co.uk or http://www.cnn.com and more giving no result. Can someone explain why this happens and how to securily check the existance of a website.
×
×
  • Create New...