Visualizzazione dei risultati da 1 a 7 su 7
  1. #1

    Whois Domini com net org

    Ciao a tutti,
    sto facendo uno script per controllare l'esistenza di un dominio.
    Mi funziona correttamente per le estensioni it e us.
    Non funziona invece per questi domini: come, net, org, info, biz.


    Vi posto il codice che uso:
    Se conoscete anche un altro script funzionante va benissimo!
    grazie
    <%Response.Buffer = true%>
    <%
    strSuffix = request("type")
    strDomainName = replace(request("name")," ","")

    'Check for .com
    If strSuffix = ".com" Then

    strReturn=whoisResult("http://www-whois.internic.net/cgi/whois?whois_nic=" & strDomainName & "&type=domain", "GET", "No match")
    flag = "internic"

    'Check for .net
    ElseIf strSuffix = ".net" Then

    strReturn=whoisResult("http://www-whois.internic.net/cgi/whois?whois_nic=" & strDomainName & "&type=domain", "GET", "No match")
    flag = "internic"

    'Check for .org
    ElseIf strSuffix = ".org" Then

    strReturn=whoisResult("http://www-whois.internic.net/cgi/whois?whois_nic=" & strDomainName & "&type=domain", "GET", "No match")
    flag = "internic"

    'Check for .info
    ElseIf strSuffix = ".info" Then

    strReturn=whoisResult("http://www-whois.internic.net/cgi/whois?whois_nic=" & strDomainName & "&type=domain", "GET", "NOT FOUND")
    flag = "internic"

    'Check for .biz
    ElseIf strSuffix = ".biz" Then

    strReturn=whoisResult("http://www-whois.internic.net/cgi/whois?whois_nic=" & strDomainName & "&type=domain", "GET", "Not found")
    flag = "internic"

    'Check for .us
    ElseIf strSuffix = ".us" Then

    strReturn=whoisResult("http://www.whois.us/whois.cgi?TLD=us&WHOIS_QUERY=" & strDomainName & "&TYPE=DOMAIN", "GET", "no records")
    flag = "whois.us"

    'Check for .it
    ElseIf strSuffix = ".it" Then

    strReturn=whoisResult("http://www.ripe.net/perl/whois?searchtext=" & strDomainName & ".it", "GET", "No entries found")
    flag = "Ripe"

    End If

    if strReturn<>"No Result" then
    if flag="internic" then

    i=instr(1,strReturn,"<pre>")
    j=instr(1,strReturn,"</pre>")
    strReturn=left(strReturn,j+5)
    strReturn=right(strReturn,len(strReturn)-i+5)

    elseif flag="whois.us" then

    i=instrrev(strReturn,"<pre>")
    j=instrrev(strReturn,"</pre>")
    strReturn=left(strReturn,j+5)
    strReturn=right(strReturn,len(strReturn)-i+1)

    elseif flag="Ripe" then

    i=instr(1,strReturn,"%REFERRAL START")
    j=instr(1,strReturn,"%REFERRAL END")
    strReturn=left(strReturn,j-5)
    strReturn=right(strReturn,len(strReturn)-i-15)

    end if
    end if


    Private Function whoisResult(whoisURL, strMethod, strCheckString)

    'Dimension variables
    Dim objXMLHTTP 'Holds the XML HTTP Object
    Dim strWhoisResultString 'Holds the reult of the whois query

    'Create an XML object to query the remote whois server
    'Set objXMLHTTP = Server.CreateObject("Microsoft.XMLHTTP")

    'Alternative XML HTTP component, for version 3.0 of XMLHTTP
    Set objXMLHTTP = Server.CreateObject("MSXML2.ServerXMLHTTP")

    'Open a connection to the remote whois server
    objXMLHTTP.Open strMethod, whoisURL, False

    'Send the request and return the data
    objXMLHTTP.Send

    'Place the whois registry response into the result string
    strWhoisResultString = objXMLHTTP.ResponseText

    'If the domain name is to short then tell them it's invalid
    If Len(strDomainName) < 3 Then

    'Set the return result of the function to not valid
    whoisResult = "Not Valid - must be at least 3 characters"

    'Check the whois result to see if a result has NOT been found
    ElseIf InStr(1, strWhoisResultString, strCheckString, vbTextCompare) Then

    'Set the return result of the function to available
    whoisResult = "No Result"

    'Else if there is an error
    ElseIF InStr(1, strWhoisResultString, "Error", vbTextCompare) Then

    'Set the return result of the function to Taken
    whoisResult = "No Result"

    'Else there was a result
    Else

    'Set the return result of the function to Taken
    whoisResult = strWhoisResultString

    End If

    'Clean up
    Set objXMLHTTP = Nothing

    End Function%>
    E va bene così... Senza parole! eeeeeeeeeeeeeeeeh

  2. #2

    Si è un casino

    ... internic ha cambiato il cgi dove si poteva fare la query... e serve anche a me ma non l'ho trovato.



    Se qualcuno sa da dove prenderlo ... grazie anche da parte mia

    Ciauzz

  3. #3
    Utente di HTML.it L'avatar di nat99
    Registrato dal
    Dec 2001
    Messaggi
    763
    scusate l'intromizzione... ma con xml-http? no è?....

  4. #4
    Con xml-http mi funziona solo per i domini it e us.

    Nient'altro!
    E va bene così... Senza parole! eeeeeeeeeeeeeeeeh

  5. #5
    Utente di HTML.it L'avatar di nat99
    Registrato dal
    Dec 2001
    Messaggi
    763
    Originariamente inviato da gtigor
    Con xml-http mi funziona solo per i domini it e us.

    Nient'altro!
    ... cerca su aspitalia... nn so dove l'ho trovato lo script ma ti assicuro che esiste...

  6. #6
    Mi hai dato una speranza! il problema è che sono 2 giorni che lo cerco e non ho trovato nulla!!!!

    Se qualcuno sa dove trovare gli script mi farebbe un enorme piacere!
    GRAZIEEE
    E va bene così... Senza parole! eeeeeeeeeeeeeeeeh

  7. #7

    whois .it

    ciao volevo sapere se mi potresti dare il whois che interroga i punti IT che a me non funziona se vuoi posso darti quello che interroga i punti COM NET ORG INFO BIZ ECC.ECC.

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.