[advanced search]
NamePros Domain Auction
Live Event This Thursday at 6PM EDT - Prebidding open now
23 members in the live chat room. Join Chat!
Register Rules & FAQ NP$ Store Active Threads Mark Forums Read
Domain Name Industry Newsletter
Go Back   NamePros.Com > Design and Development > Programming > CODE
User Name
Password

Old 01-22-2007, 08:05 AM   · #1
3l3ctr1c
DNOA Member
 
Trader Rating: (6)
Join Date: May 2006
Posts: 256
NP$: 68.15 (Donate)
3l3ctr1c has a spectacular aura about3l3ctr1c has a spectacular aura about
Cool [PHP+AJAX] Domain Availabilty Checker - Checks tlds

Hey everyone!

First credits go to ADAM and MATTEW for the basic script all I did to this was made it AJAX.

Demo :


A live demo goes here at my blog http://www.hakc.net/scripts/domainjax/

I've got to add much more to this script so beat at your seats! I'll be adding more web 2.0 features!

Script
The Index file :
Code:
<html> <body> <head> <title></title> </head> <link href="main.css" rel="stylesheet" /> <script language="javascript" type="text/javascript" src="ajax.js"></script> <center> <form method="post" action="./" id="form"> <input type="text" name="domain" /> <br /><br /><input type="submit" value="Check Availability" style="font-size: 10pt;" /> </form> <div id="loading"><img src="inc/loading.gif"></img></div> <div id="results"></div> </center> </body> </html>


The AJAX handler :

Code:
var xml = makeXML(); var form; var loading; var results; function makeXML () { if (typeof XMLHttpRequest == 'undefined') { objects = Array( 'Microsoft.XmlHttp', 'MSXML2.XmlHttp', 'MSXML2.XmlHttp.3.0', 'MSXML2.XmlHttp.4.0', 'MSXML2.XmlHttp.5.0' ); for (i = 0; i < objects.length; i++) { try { return new ActiveXObject(objects[i]); } catch (e) {} } } else { return new XMLHttpRequest(); } } window.onload = function () { form = document.getElementById('form'); loading = document.getElementById('loading'); results = document.getElementById('results'); form.onsubmit = function () { results.style.display = 'none'; results.innerHTML = ''; loading.style.display = 'inline'; xml.open('get', './process.php?domain=' + escape(this.domain.value)); xml.onreadystatechange = function () { if (xml.readyState == 3 && xml.status == 200) { results.style.display = 'block'; results.innerHTML = xml.responseText; loading.style.display = 'none'; } } xml.send(null); return false; } }


Download the complete Package here !

Script is totally free to use modify and use anywhere wanted, but cannot be sold under any circumstances.

-- 3l3ctr1c


Please register or log-in into NamePros to hide ads
3l3ctr1c is offline  
  Reply With Quote
Old 01-22-2007, 08:11 AM   · #2
Stitch
NamePros Member
 
Trader Rating: (7)
Join Date: Dec 2006
Posts: 141
NP$: 0.00 (Donate)
Stitch is on a distinguished road
Not bad, but AJAX really needed for 1 submit form?

I dont think AJAX is necessary for this.
Stitch is offline   Reply With Quote
Old 01-22-2007, 09:58 AM   · #3
Matthew.
Stud Sausage
 
Location: England
Trader Rating: (25)
Join Date: Dec 2006
Posts: 1,545
NP$: 32.41 (Donate)
Matthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud of
Adoption Breast Cancer Breast Cancer Cancer Survivorship
Originally Posted by . Adam .
Not bad, but AJAX really needed for 1 submit form?

I dont think AJAX is necessary for this.



Although they are my words (adam - ) it depends on how it is used i guess, personally for something like this i don't recommend ajax but i suppose it does no harm.

Thanks for the credits 3l3ctr1c
__________________
My NamePros Tools
(firefox plugin, google gadget etc)
Matthew. is online now   Reply With Quote
Old 01-22-2007, 10:35 AM   · #4
Stitch
NamePros Member
 
Trader Rating: (7)
Join Date: Dec 2006
Posts: 141
NP$: 0.00 (Donate)
Stitch is on a distinguished road
lol

Yea thanks for credits
Stitch is offline   Reply With Quote
Old 01-23-2007, 02:39 AM   · #5
3l3ctr1c
DNOA Member
 
Trader Rating: (6)
Join Date: May 2006
Posts: 256
NP$: 68.15 (Donate)
3l3ctr1c has a spectacular aura about3l3ctr1c has a spectacular aura about
I felt like ajaxing it, and did it, but I love to see AJAX everywhere! Actually the ready.state was set to 3 so that results can be shown as they're fetched but I don't know what changed after it went to my host.
3l3ctr1c is offline  
  Reply With Quote
Old 01-25-2007, 07:47 AM   · #6
Hitch
Adrian
 
Hitch's Avatar
 
Name: Adrian
Location: Uk, South Yorkshire
Trader Rating: (10)
Join Date: Aug 2005
Posts: 1,227
NP$: 16.00 (Donate)
Hitch is a splendid one to beholdHitch is a splendid one to beholdHitch is a splendid one to beholdHitch is a splendid one to beholdHitch is a splendid one to beholdHitch is a splendid one to beholdHitch is a splendid one to behold
Winner
PHP Programming - May 2007 Animal Rescue Third World Education Find Marrow Donors!
I prefer AJAX actually.

Gives it a more, modern, professional feel.
__________________
NamePros
Hitch is offline   Reply With Quote
Old 02-17-2007, 05:35 PM   · #7
-NB-
Formerly Array
 
-NB-'s Avatar
 
Name: Nick Berlette
Location: San Diego, CA
Trader Rating: (44)
Join Date: Feb 2006
Posts: 229
NP$: 139.50 (Donate)
-NB- is a name known to all-NB- is a name known to all-NB- is a name known to all-NB- is a name known to all-NB- is a name known to all-NB- is a name known to all
What about credit to me for coming up with that beautiful AJAX system? Stealing code and claiming as your own is not cool
-NB- is offline   Reply With Quote
Old 02-17-2007, 05:38 PM   · #8
Matthew.
Stud Sausage
 
Location: England
Trader Rating: (25)
Join Date: Dec 2006
Posts: 1,545
NP$: 32.41 (Donate)
Matthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud of
Adoption Breast Cancer Breast Cancer Cancer Survivorship
Originally Posted by -NB-
What about credit to me for coming up with that beautiful AJAX system? Stealing code and claiming as your own is not cool



None of my business but if you're going to post in a public forum accusing the OP of stealing code, then would it not be prudent to post some sort of proof?

Matt
__________________
My NamePros Tools
(firefox plugin, google gadget etc)
Matthew. is online now   Reply With Quote
Old 02-17-2007, 05:59 PM   · #9
Dan
Buy my domains.
 
Dan's Avatar
 
Name: Dan
Trader Rating: (63)
Join Date: Feb 2006
Posts: 2,801
NP$: 54.00 (Donate)
Dan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant futureDan has a brilliant future
Autism Autism Autism Autism Autism Autism Autism
I posted this before this was posted and it's an AJAX domain checker.

-NB-, I don't think you invented AJAX and it's not the most beautiful thing I've ever seen.
Dan is offline   Reply With Quote
Old 03-11-2007, 11:09 PM   · #10
navjotjsingh
BlahBlahBlah...
 
navjotjsingh's Avatar
 
Name: Navjot Singh
Location: India
Trader Rating: (37)
Join Date: Oct 2005
Posts: 1,941
NP$: 0.51 (Donate)
navjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to beholdnavjotjsingh is a splendid one to behold
Marrow Donor Program
It does not work in IE 6 and IE 7. Shows javascript error in status bar and script keeps on searching...no results. Please fix it.
navjotjsingh is offline   Reply With Quote
Old 03-18-2007, 10:36 AM   · #11
killaklown
Senior Member
 
Name: Justin
Location: Winnipeg, Canada
Trader Rating: (73)
Join Date: Oct 2003
Posts: 3,467
NP$: 0.06 (Donate)
killaklown is a splendid one to beholdkillaklown is a splendid one to beholdkillaklown is a splendid one to beholdkillaklown is a splendid one to beholdkillaklown is a splendid one to beholdkillaklown is a splendid one to beholdkillaklown is a splendid one to behold
Nice script, but it seems a little buggy at times.
__________________
FENOO image hosting
killaklown is offline   Reply With Quote
Old 03-18-2007, 11:46 AM   · #12
cef
NamePros Regular
 
Location: NYC
Trader Rating: (8)
Join Date: May 2004
Posts: 234
NP$: 75.00 (Donate)
cef is a jewel in the roughcef is a jewel in the roughcef is a jewel in the rough
Animal Rescue
Yupl, a little buggy. I typed in stargate.com (where I have my server) and got this back:

Quote:
stargate.com.com is Available
stargate.com.net is Available
stargate.com.org is Available
stargate.com.biz is Available
stargate.com.tv is Available
stargate.com.info is Available
stargate.com.co.uk is Taken
stargate.com.nl is Taken
stargate.com.ca is Taken
stargate.com.name is Taken
stargate.com.ws is Available
stargate.com.be is Taken



First, because com.com is taken, Nothing else under it should be listed as available.

That said, the script should parse input a little better to account for how TLDs are actually used (e.g. .co.uk vs. .com.com sort of thing) and to strip/not strip things as appropriate (also add TLDs if none present).

Other than that, looks nice so far.
cef is offline   Reply With Quote
Old 03-18-2007, 12:48 PM   · #13
3l3ctr1c
DNOA Member
 
Trader Rating: (6)
Join Date: May 2006
Posts: 256
NP$: 68.15 (Donate)
3l3ctr1c has a spectacular aura about3l3ctr1c has a spectacular aura about
I'll try to fix them up asap.

3l3ctr1c
3l3ctr1c is offline  
  Reply With Quote
Closed Thread

NamePros is a revenue sharing forum.

Thread Tools

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 On
[IMG] code is Off
HTML code is Off
Forum Jump


Site Sponsors
http://www.mobisitetrader.com/ Find out how! http://www.mobisitetrader.com/
Advertise your business at NamePros
All times are GMT -7. The time now is 04:49 PM.


Powered by: vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0