'.$_nl;
$_out .= ''.$_nl;
$_out .= ''.$_nl;
$_out .= '| '.$_nl;
$_out .= ''.$_sp.''.$_nl;
$_out .= ' | '.$_nl;
$_out .= ''.$_nl;
$_out .= ''.$_LANG['_WHOIS']['Title_Available'].''.$_nl;
$_out .= ' | '.$_nl;
$_out .= ''.$_nl;
$_out .= ''.$_LANG['_WHOIS']['Title_Taken'].''.$_nl;
$_out .= ' | '.$_nl;
$_out .= ''.$_nl;
$_out .= ''.$_sp.''.$_nl;
$_out .= ' | '.$_nl;
$_out .= ''.$_nl;
$_out .= ''.$_sp.''.$_nl;
$_out .= ' | '.$_nl;
$_out .= ' '.$_nl;
FOR ( $x=0; $x < $Lookups; $x++ ) {
IF ((($_GPV[type] == "all") || ($_GPV[type] == $Lookup_Domain['value'][$x])) && $Lookup_Domain['include'][$x]) {
# Custom to get multiple lookups from one item
IF ($Lookup_Domain['value'][$x] == 'com' && $Lookup_Domain['display'][$x] == '.com .net') {
$dom_array = array($_GPV[ord_domain].'.com', $_GPV[ord_domain].'.net');
} ELSEIF ($Lookup_Domain['value'][$x] == 'uk' && $Lookup_Domain['display'][$x] == '.co.uk .org.uk .me.uk') {
$dom_array = array($_GPV[ord_domain].'.co.uk', $_GPV[ord_domain].'.org.uk', $_GPV[ord_domain].'.me.uk');
} ELSEIF ($Lookup_Domain['value'][$x] == 'pl' && $Lookup_Domain['display'][$x] == '.pl .com.pl') {
$dom_array = array($_GPV[ord_domain].'.pl', $_GPV[ord_domain].'.com.pl');
} ELSE {
$dom_array = array($_GPV[ord_domain].'.'.$Lookup_Domain['value'][$x]);
}
$dom_count = count($dom_array);
$i=0;
FOR ($i=0; $i < $dom_count; $i++) {
$domname = $dom_array[$i];
$result = '';
# Some Registrars now insert domain name into return
$Lookup_Domain['nomatch'][$x] = str_replace('%ORD_DOMAIN%', $domname, $Lookup_Domain['nomatch'][$x]);
$Lookup_Domain['server'][$x] = str_replace('%ORD_DOMAIN%', $domname, $Lookup_Domain['server'][$x]);
# Support .co.za
IF ($Lookup_Domain['value'][$x] == 'co.za') {
IF (!ini_get('allow_url_fopen')) {
$result = 'disabled';
} ELSE {
$lines = file('http://'.$Lookup_Domain['server'][$x]);
foreach ($lines as $line_num => $line) {$result .= $line;}
}
# Support .mt
} ELSEIF ($Lookup_Domain['value'][$x] == 'com.mt' || $Lookup_Domain['value'][$x] == 'net.mt' || $Lookup_Domain['value'][$x] == 'org.mt' ) {
IF (!ini_get('allow_url_fopen')) {
$result = 'disabled';
} ELSE {
$lines = file('https://'.$Lookup_Domain['server'][$x]);
foreach ($lines as $line_num => $line) {$result .= $line;}
}
# Normal WHOIS lookup
} ELSE {
$ns = fsockopen($Lookup_Domain['server'][$x], 43, $errno, $errstr, 10);
fputs($ns,"$domname\r\n");
while(!feof($ns)) {$result .= fgets($ns,128);}
fclose($ns);
}
$result = trim($result);
# Some registrars now insert extra spaces and carriage returns into results
$result = str_replace(' ', '', $result);
$result = str_replace("\n", '', $result);
$result = str_replace("\r", '', $result);
$NoMatch = str_replace(' ', '', $Lookup_Domain['nomatch'][$x]);
IF (eregi($NoMatch, $result) !== FALSE) {
// Over-ride product_id ordered, if set in array above,
// otherwise pass back ord_prod_id originally ordered.
IF ($Lookup_Domain['prod_id'][$i]) {
$prodid = $Lookup_Domain['prod_id'][$i];
} ELSE {
$prodid = $_REQUEST[ord_prod_id];
}
$_out .= dispav($domname,$prodid);
} ELSEIF ($result == 'disabled') {
$_out .= dispdi($domname);
} ELSE {
$_out .= dispun($domname,$Lookup_Domain['server'][$x]);
}
}
$_out .= '| | '.$_nl;
}
}
$_out .= ' '.$_nl;
$_out .= ' |