Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #5182

Re: example CURL to form in Https

From "J.O. Aho" <user@example.net>
Newsgroups comp.lang.php
Subject Re: example CURL to form in Https
Date 2012-03-18 14:37 +0100
Message-ID <9sm6oiFch6U1@mid.individual.net> (permalink)
References <ee1af577-8952-410a-965e-7d7af6a9ee3c@2g2000yqk.googlegroups.com> <jk1l6s$u7n$1@dont-email.me> <2e735f94-dbcc-4ff1-9c49-bb11064ce5ad@w5g2000yqi.googlegroups.com> <jk28lr$stt$1@dont-email.me> <3e5a290d-a28d-434a-a3d4-2cb7c2db087d@i5g2000yqo.googlegroups.com>

Show all headers | View raw


Vivian wrote:

<Cut away non needed text as mail footers and things not replayed to>

> where is wrong ? show the blank page only...
 >
> // CLOSE CURL
> curl_close ($ch);
>
> ?>

If you don't make any output, then you will not get anything else than a blank 
page.


> // EXECUTE 1st REQUEST (FORM LOGIN)
> $store = curl_exec ($ch);
>
>
> // EXECUTE 2nd REQUEST (FILE DOWNLOAD)
> $content = curl_exec ($ch);

Are you sure making the same request (login) will give you the content?
Are you even sure your login was successful? It may be good to use 
curl_error() to see if something went wrong (if login fails, fetching file 
will also fail and no point in trying to do that if the login failed).


-- 

   //Aho

Back to comp.lang.php | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

example CURL to form in Https Vivian <viviansank@gmail.com> - 2012-03-16 19:44 -0700
  Re: example CURL to form in Https Jerry Stuckle <jstucklex@attglobal.net> - 2012-03-17 05:23 -0400
    Re: example CURL to form in Https Vivian <viviansank@gmail.com> - 2012-03-17 06:38 -0700
      Re: example CURL to form in Https Jerry Stuckle <jstucklex@attglobal.net> - 2012-03-17 10:55 -0400
        Re: example CURL to form in Https Vivian <viviansank@gmail.com> - 2012-03-18 05:49 -0700
          Re: example CURL to form in Https "J.O. Aho" <user@example.net> - 2012-03-18 14:37 +0100

csiph-web