On 12/02/2014 05:19 AM, Suliman wrote:
connect() sends a "CONNECT" request to the server, as defined by HTTP
[1]. This method is only used when you're working with proxies and the
like. What you most likely want, however, is a "GET" request. Use
get() for that.
So what is the best way to chec
connect() sends a "CONNECT" request to the server, as defined
by HTTP [1]. This method is only used when you're working with
proxies and the like. What you most likely want, however, is a
"GET" request. Use get() for that.
So what is the best way to check status server response (400, 404
et
On Monday, 1 December 2014 at 19:44:56 UTC, Suliman wrote:
My guess is that you have to use HTTPS for CONNECT and that
you have to have credentials for it. (?)
Ali
dlang.org should work on HTTP, but not HTTPS.
Also I do not think that when I connect to HTTPS I should have
any credentials. I
My guess is that you have to use HTTPS for CONNECT and that you
have to have credentials for it. (?)
Ali
dlang.org should work on HTTP, but not HTTPS.
Also I do not think that when I connect to HTTPS I should have
any credentials. It's mostly like issue with curl...
On 12/01/2014 10:25 AM, Suliman wrote:
> why:
> string link = "dlang.org";
> writeln(connect(link));
>
> cause crash:
(To be pedantic: An unhandled exception is not a crash. ;) )
>
std.net.curl.CurlException@C:\DMD\dmd2\windows\bin\..\..\src\phobos\std\net\curl
>
> .d(779): HTTP r
Big thanks Ali!
Only the small last question:
why:
string link = "dlang.org";
writeln(connect(link));
cause crash:
std.net.curl.CurlException@C:\DMD\dmd2\windows\bin\..\..\src\phobos\std\net\curl
.d(779): HTTP request returned status code 400
0x00404263
0x00402
On 11/30/2014 10:38 PM, Suliman wrote:
> Am I right understand all exception are derived from "assertThrown"
> http://dlang.org/phobos/std_exception.html
No, all exceptions are derived from Throwable. It has two descendants:
- Error, representing conditions that are irrecoverable, and
- Except
On Sunday, 30 November 2014 at 19:24:39 UTC, Suliman wrote:
I can't understand why I am getting exception on next code:
void downloadFile()
{
foreach(link; links)
{
try
{
Am I right understand all exception are derived from
"assertThrown"
http://dlang.org/phobos/std_exception.html
So "msg" in "catch(Exception msg)" is from function
"assertThrown"?
Could you show me example of how to handle type of exception?
This is turning out to be a common problem. :)
On 11/30/2014 11:24 AM, Suliman wrote:
> I can't understand why I am getting exception on next code:
>
> void downloadFile()
> {
> foreach(link; links)
> {
> try
> {
> writeln(con
I can't understand why I am getting exception on next code:
void downloadFile()
{
foreach(link; links)
{
try
{
writeln(connect(link));
}
11 matches
Mail list logo