DNS Java Search

I've always had to lookup current status of domain names for clients. Recently I decided why not create my own tools to help with the task.

Live Example

Java documentation.

See the code below.


screen scrape code (Whois)

An example of a UDF and screen scraper

<form method="get">
	www. <input type="Text" name="string" value="<cfif isdefined('url.string')><cfoutput>#url.string#</cfoutput></cfif>">
	<input type="Submit" value="check this domain">
<cfif isdefined('url.string')>
	<cfhttp method="get" url=""  result="test" resolveurl="true"></cfhttp>
	<cfset thisPage = test.filecontent>
	<cfset scraped = scrape(thisPage, '<div id="registryBlk">', '<div class="whois_rhs_column">', 'Available...')>
	<cfset scraped2 = scrape(scraped, 'Domain Name: ', '<br>','Available...')>
<cffunction name="scrape">
	<cfargument  name="searchMe">
	<cfargument  name="startHere">
	<cfargument name="endHere">
	<cfargument name="notfoundmsg" default="">
	<cfset firstNum = Find(startHere, SearchMe)>
	<cfif firstnum eq 0>
		<cfset result = notfoundmsg>
		<cfset lastNum = Find(endHere,SearchMe,firstNum)>
		<cfset counting = lastNum - firstNum>
		<cfset result= Mid(searchMe, firstNum, counting)>
	<cfreturn result>

RTFM - BlogCFC by Ray Camden

Read The Fine Manual for this fine blog software created by Ray Camden.
Self Logic
5019 Darnell st
Houston, TX 77096