Solved

Simple XMLHttpRequest Search & Display

Posted on 2006-10-30
12
352 Views
Last Modified: 2008-01-09
__________________________________________________

I'd like to create a "simple" web application that allows users to search for available domain names.

As they type a domain name into the search field, the results are populated below (without the need for a submit button).

However, it would search using GET requests, like:

http://www.site,com/search.php?domain=DOMAIN

It would then tell the user which extension is available for their chosen domain name:

Such as:

somedomain.com = Available
somedomain.net = Unavailable
somedomain.org = Available

and then return each result as a link like:

http://www.site,com/info.php?domain=DOMAIN


Hope this isn't too complicated...

Thanks...
0
Comment
Question by:Web_Zap
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
12 Comments
 
LVL 15

Expert Comment

by:SnowFlake
ID: 17840207
what is your Q ?
0
 

Author Comment

by:Web_Zap
ID: 17845575
I need help creating this.
0
 

Author Comment

by:Web_Zap
ID: 17853640
Can anyone help?
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 15

Expert Comment

by:SnowFlake
ID: 17853953
you are not getting many responses as people here don't feel its their task to do other people's work
without being paid for it.
people are here to HELP, and ANSWER Q's, and TEACH.

if you need help your Q should go something like:
I am trying to ....
So far I did ....
However ....
Does anybody know howto/why/..... ?

So,
what have you done so far ?
what technology are you using ?
who are the clients for this and what is the domain that you plan to make the searches against ?

what do you mean when you say:
"As they type a domain name into the search field, the results are populated below (without the need for a submit button)."
does that mean that if I type bigredcars

I will get
b.com
b.net
b.org
bi.com
bi.net
bi.org
big.com
and so on
?????

SnowFlake



0
 

Author Comment

by:Web_Zap
ID: 17854723
I never said I wanted anyone to create this project for me.

Please re-read my original post. I said "I'd like to create a "simple" web application that allows users to search for available domain names."

Notice I used the phrase "I'd like to create"? I never said "I'd like YOU to create".

Anyways, yes, basically just a live search that populates the results as they type.

An example would be nice.

Thanks!
0
 
LVL 15

Expert Comment

by:SnowFlake
ID: 17856233
what would you have running on the server-side ?
IMHO - if your page comes from one domain you will not be able to get the results from another one - on the client side - unless you are running something with elevated permissions - like an .HTA (html application).
if you would like to do this from the backend however - your solution would depend on your server side technology.

would you like an example for .NET ?
0
 

Author Comment

by:Web_Zap
ID: 17856831
I would have PHP on the server side.

Also, let's say, that the searches would be made using: http://www.networksolutions.com

Thanks again.
0
 
LVL 15

Accepted Solution

by:
SnowFlake earned 134 total points
ID: 17861209
well, on that case (since I don't know Any PHP) I would suggest that you ask you Q again in the php TA (http://www.experts-exchange.com/Web/Web_Languages/PHP/)
for the backend support support,
and I guess that would also be a good place to ask about an AJAX framework that works with PHP.

If you want to get better understanding of related topic before you ask again you can search up on "xmlhttp" and on "ajax".

good luck,

SnowFlake
0
 
LVL 1

Assisted Solution

by:kurnia
kurnia earned 133 total points
ID: 17872456
Hi,
here is an Ajax example http://www.clearnova.com/ajax/
perhaps you can learn from there.

0
 
LVL 11

Assisted Solution

by:kelvinwkw
kelvinwkw earned 133 total points
ID: 17935975
<html>
      <body>
<script>
      <!--
      function domainLookup(domainName){
            try {
          xmlhttp = window.XMLHttpRequest ? new XMLHttpRequest():      new ActiveXObject("Microsoft.XMLHTTP");
        }catch (e) { document.write("Non Ajax support browser");}
    var m_url = "http://examples.softwaremodules.com/IntraDns.asp?domainname=" + domainName + "&Submit=Submit&t_a=1&t_mx=1&t_ns=1";
    xmlhttp.open("GET", m_url, false);
    xmlhttp.send();
    if ((xmlhttp.readyState == 4) && (xmlhttp.status == 200)){
          var responseText = xmlhttp.responseText;
          var preText = "DNS Lookup (A) for <strong>" + domainName + "</strong>. Items Returned: <strong>";
          var preTextLoc = responseText.indexOf(preText) + preText.length;
          var lookupInfo = responseText.substring(preTextLoc, preTextLoc + 1);
             if (lookupInfo != "0" ){
                   document.getElementById("domainDetail").innerHTML = "Occupied";      
             }else{
                         document.getElementById("domainDetail").innerHTML = "Available";      
            }
        }        
      }
-->
</script>
<div id="domainDetail"></div>
<form name="form">
      <input name="domain" size="30"/>
      <input type="button" value="Domain Lookup" onclick="domainLookup(document.form.domain.value);"/>
</form>
</body>
</html>


try one of this

in HTML
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Some high points and examples of what's great about Facebook React? 5 200
AngularJS directive issue 6 80
Re-position the objects 7 125
Randomize in Owl Carousel v1.3.2 6 100
Preface This article introduces an authentication and authorization system for a website.  It is understood by the author and the project contributors that there is no such thing as a "one size fits all" system.  That being said, there is a certa…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question