1. Go to this page and download the library: Download sincco/curl 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/ */
sincco / curl example snippets
use Sincco\Tools\Curl;
$url = 'https://www.amazon.com.mx';
$curl = new \Sincco\Tools\Curl;
$curl->addOption(CURLOPT_CONNECTTIMEOUT, 100);
var_dump($curl->get($url));
use Sincco\Tools\Curl;
$url = 'https://www.amazon.com.mx';
$curl = new \Sincco\Tools\Curl;
$curl->addOption(CURLOPT_CONNECTTIMEOUT, 100);
$domPage = $curl->getDom($url);
foreach ($domPage->find('div[class=s-item-container] a[class=a-link-normal s-access-detail-page a-text-normal]') as $item) {
var_dump($item->href);
}