PHP code example of ch1p / php-fastdns
1. Go to this page and download the library: Download ch1p/php-fastdns library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
ch1p / php-fastdns example snippets
use ch1p\FastDNS;
use ch1p\FastDNSException;
$fastdns = new FastDNS();
try {
// авторизуемся
$fastdns->auth('ВАШ ТОКЕН');
// готово
// для примера, получим список доменов
$domains = $fastdns->getDomains();
var_dump($domains);
} catch (FastDNSException $e) {
// что-то пошло не так
}
shell
composer