curl-and-php
Re: File Upload & Post problem - libcurl + PHP
Date: Tue, 2 May 2006 15:47:24 -0700 (PDT)
Hi,
Has anyone tried to extract the dynamic '_VIEWSTATE' variable from PHP code and then post parameters including the extracted '_VIEWSTATE' variable and also upload a file to a site using cURL?.
Right now, i am trying to Post parameters including '_VIEWSTATE' variable & Upload file using PHP , libcurl but unable to upload as decribed in my previous messages.
If you have posted _VIEWSTATE and uploaded using cURL, please share your ideas or code on the same, would be grateful to you.
Thanks,
LP
Daniel Stenberg <daniel_at_haxx.se> wrote:
On Tue, 2 May 2006, lakshmipriya prabhu wrote:
> I am not using the command line client (--trace-ascii option cannot be
> used) because i need to capture the dynamic "_VIEWSTATE" variable which
> needs to be posted to the site which is not possible with the cURL.
Sure it is, you'd just extract the stuff you need and invoke curl. It is even
a lot easier if you ask me (but then I don't know much PHP).
> Even if i disable the CURLOPT_VERBOSE i get the same problem (File not
> getting uploaded and the parameters not getting posted.)
I certainly didn't mean that CURLOPT_VERBOSE caused your problem. I only
explained why you didn't see the trace output you missed.
> I am using HTTP analyser to track the request/response, cookie etc and
> emulating it in my code.
Then HTTP analyze both a manual operation and then your scripted version and
compare the requests.
> Could you suggest what is getting missed from my part for the upload and
> post not happening.
Sorry, but no. I already guide you to use/debug with libcurl properly and you
do your programming parts.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.html _______________________________________________ http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php --------------------------------- Get amazing travel prices for air and hotel in one click on Yahoo! FareChase
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2006-05-03