Hello.
I have pick up a script from internet to track errors from curl command.
#!/bin/bash
#
URL_TO_TEST="http://www.xxxxxx.yyy"
MY_VAR=curl_init("$URL_TO_TEST") ;
curl_setopt($MY_VAR, CURLOPT_HEADER, 1);
curl_setopt($MY_VAR, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($MY_VAR, CURLOPT_HTTPGET, 1);
curl_setopt($MY_VAR, CURLOPT_URL, "$URL_TO_TEST" );
curl_setopt($MY_VAR, CURLOPT_DNS_USE_GLOBAL_CACHE, false );
curl_setopt($MY_VAR, CURLOPT_DNS_CACHE_TIMEOUT, 2 );
var_dump(curl_exec($MY_VAR));
var_dump(curl_getinfo($MY_VAR));
var_dump(curl_error($MY_VAR));
It does not work because I think that the syntax is for php.
Googleing does not help me.
Any help is welcome.