Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Old 10-04-2004, 03:12 PM cURL Question
Junior Talker

Posts: 2
Trades: 0


I have a curl script on page 1 that will post some values to page 2. Currently when page 1 performs the post using curl, page 1 stays waiting for a response from page 2. I don't want page 1 to sit idly by until page 2 returns something. I want page 1 to do the post with curl and continue executing any code left on that page. In other words, i want this post to be asynchronous. Below I have posted my script for the curl post. Any help will be greatly appreciated.

******************************************

$posturl = "url i'm posting to";
$postvalues = "var1=val1&var2=val2";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,$posturl);
curl_setopt($ch, CURLOPT_RETURNTRANSFER,0);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_POSTFIELDS, $postvalues);
curl_exec($ch); // this is where it stays waiting until something returns from page 2.

******************************************
virdei is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Reply     « Reply to cURL Question
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.08123 seconds with 12 queries