Categoria
Códigos adicionados no site: 23
Temas para Código
List RBL (Real-time Blackhole List) Check
Palavras-chaves: RBL,Spam,IP,E-mail |
Cadastro: 29/01/2026 22:54:26 | Atualização: 29/01/2026 22:57:26
Cadastro: 29/01/2026 22:54:26 | Atualização: 29/01/2026 22:57:26
function RBL_Check($ip)
{
try {
$rblurl = 'http://rbl-check.org/rbl_api.php?ipaddress=' . trim($ip);
$boom = fopen($rblurl, "r");
$rbl = stream_get_contents($boom);
fclose($boom);
$lines = explode("\n", $rbl);
$table = "<table class='table table-bordered table-striped'><thead><tr>
<th>Nome</th><th>Servidor</th><th>Website</th><th>Status</th>
</tr></thead><tbody>";
foreach ($lines as $index => $line) {
$table .= "<tr>";
$cols = explode(";", $line);
foreach ($cols as $col) {
if ($col == 'notlisted') {
$table .= "<td class='text-center'><i class='fas fa-check-circle text-success'></i></td>";
} else if ($col == 'listed') {
$table .= "<td class='text-center'><i class='fas fa-check-circle text-danger'></i></td>";
} else if (str_contains($col, "http")) {
$table .= "<td><a href='" . htmlspecialchars($col) . "' target='_blank'>" . htmlspecialchars($col) . "</a></td>";
} else if ($col == 'nowebsite') {
$table .= "<td>Sem Website</td>";
} else {
$table .= "<td>" . htmlspecialchars($col) . "</td>";
}
}
$table .= "</tr>";
}
$table .= "</tbody></table>";
echo $table;
} catch (\Throwable $th) {
throw $th;
}
}