- Impact
- 3
PHP:
Domain Availabilty Checker - Checks tlds - Version: 1.0.0.0[/b]
Hello,
This is my first script on this site, and seeing [URL=http://www.namepros.com/code/280961-php-bulk-domain-availability-check.html]Matthew. 's Script[/URL] I decided to make one a little different. Instead of checking multiple domains, this one checks multiple tlds!
[SIZE=4]
[B]Demo[/B][/SIZE]
A live demo of this can be found here: [url]http://70.85.180.226/~thetopto/Scripts/Domain_Checker/[/url]
Some of this script uses Matthews. code, I obviously have permission as Matt is a good friend and yes I did ask first.
[SIZE=4]
[B]How To Use:[/B][/SIZE]
Enter something like:
[list=a]
[*]techtuts
[*]namepros
[*]pixel2life
[*]lmao
[*]sitename
[/list]
and it will return the availability of each tld told to in the script. Saves typing all domains out in matts ;)
Anyway, your waiting to see the script arent ya :)
[SIZE=4]
[B]The Script:[/B][/SIZE]
[PHP]<?php
set_time_limit(0);
ob_start();
/*
| ---------------------------------------------------
| > Script Name: Domain Availabilty Checker
| > By: Adam
| > Website: www.portfoliosp.com
| > Version: 1.0.0.0
|
| -- Credits:
| > With thanks to Matt Jewell (Matthew.) | www.mattjewell.com
|
| -- IMPORTANT --
| This copyright notice must be left intact. Feel free to modify this script.
| This script may NOT be sold under any circumstances!
| ---------------------------------------------------
*/
include 'inc/dnservers.php';
###########################################
if(isset($_POST['submit']))
{
$domain = str_replace(array('www.', 'http://'), NULL, $_POST['domain']);
if(strlen($domain) > 0)
{
echo '<h2>Checking Domain</h2>';
echo 'Please wait while the results are processed....<br /><br />';
foreach($ext as $extension => $who)
{
$buffer = NULL;
$sock = fsockopen($who[0], 43) or die('Error Connecting To Server:' . $server);
fputs($sock, $domain.$extension . "\r\n");
while( !feof($sock) )
{
$buffer .= fgets($sock,128);
}
fclose($sock);
if(eregi($who[1], $buffer))
{
echo '<div style="color: green;">' . $domain . $extension .' is Available</div>';
}
else
{
echo '<div style="color: red;">' . $domain . $extension .' is Taken</div>';
}
ob_flush();
flush();
sleep(0.3);
}
echo '<h2>Completed</h2>';
}
else
{
echo 'Please enter the domain name';
}
}
else
{
?>
<div style="text-align: center">
<form method="post">
<input type="text" name="domain" />
<br /><br /><input type="submit" name="submit" value="Check Availability" style="font-size: 10pt;" />
</form>
</div>
<?php
} // The End
?>
This is the first version of this script and may have a few bugs.
Script details:
/*
| ---------------------------------------------------
| > Script Name: Domain Availabilty Checker
| > By: Adam
| > Website: www.portfoliosp.com
| > Version: 1.0.0.0
|
| -- Credits:
| > With thanks to Matt Jewell (Matthew.) | www.mattjewell.com
|
| -- IMPORTANT --
| This copyright notice must be left intact. Feel free to modify this script.
| This script may NOT be sold under any circumstances!
| ---------------------------------------------------
*/
Download
Download script HERE
-----
The script is free to use, and you may distribute. You must NOT sell in anyway. You can modify it if you wish. Just leave copyright intact!
Enjoy, and look out for future versions!
Please post bugs and suggestions below.
Thanks,
Adam
Last edited: