PHP - What does this do?
What does this do? $running = null; { curl_multi_exec($mh,$running); usleep(100000); } while ($running > 0); Also: curl_setopt($ch, CURLOPT_TIMEOUT, 8); Its PHP and curl. ...
What does this do? $running = null; { curl_multi_exec($mh,$running); usleep(100000); } while ($running > 0); Also: curl_setopt($ch, CURLOPT_TIMEOUT, 8); Its PHP and curl. ...
I am using PHP with the Amazon Payments web service. I'm having problems with some of my requests. Amazon is returning an error as it should, however the way it goes about it is giving me problems. Amazon returns XML data with a message about the error, but it also throws an HTTP 400 (or even 404 sometimes). This makes file_get_contents...
I want to try figure out how to get the <title>A common title</title> <meta name="keywords" content="Keywords blabla" /> <meta name="description" content="This is the description" /> Even though if it's arranged in any order, I've heard of the PHP Simple HTML DOM Parser but I don't really want to use it. Is it possible for a solution ...
Hi All, I am using curl to send xml requests to API from Emailvision. I am having trouble lately where some requests result in "500 Internal Server Error", while others are sent without any errors. The output of verbose is pasted below, can someone please help me interpret what might be causing the error. * About to connect() to api....
Hi I have implemented the Authorize.net payment method in my web site. I have sent the billing info and payment into to the autorize.net. But I want to send the shipping information too. I am using the following code "x_first_name" => $firstname, "x_last_name" => $lastname, "x_address" => $bill_address, "x_city" => $bill_city...
I have enabled cookie engine in curl using curl_easy_setopt on CURLOPT_COOKIEFILE and CURLOPT_COOKIEJAR. In the response from server, the cookies are set. In subsequent requests, CURL is not sending cookies along with the request only if it is a POST request. For GET requests CURL is sending cookies along. Should I indicate CURL in s...
I am in the process of making a page fetch script & I was using curl for it. I used the function: get_data($url); but I always get the error: Fatal error: Call to undefined function get_data() in D:\wamp\www\grab\grab.php on line 16 I am using WAMP server and I have enabled curl extentions in all the ini files, I have checked the ex...
I'm using libevent2 for building a server, and I'm trying to enable the server to use libcurl asynchronously, and I'm wondering about how I do that with libevent2. I would like to be able to get curl to send events so I can inspect the current state. Update: I figured it out http://github.com/mathgladiator/node.ocaml/blob/master/ext/s...
I want to use curl to get a stream from a remote server, and write it to a buffer. So far so good I just do curl http://the.stream>/path/to/thebuffer. Thing is I don't want this file to get too large, so I want to be able to delete the first bytes of the file as I simultaneously add to the last bytes. Is there a way of doing this? A...
How can I retrieve all the direct messages of inbox of my twitter account using token oauth OR curl in PHP? ...
To refresh Redmine, I need SVN to ping our Redmine installation from our post-commit hook. Our post-commit hook is a Ruby script that generates an email. I'd like to insert a call do this: curl --insecure https://redmineserver+webappkey This call works from the command line but when I try to do this: #!/usr/bin/ruby -w REFRESH_DRADIS...
Hello I just start to develop php what I want to do is to get xml contents from another site but when i get it like this $options = array( CURLOPT_RETURNTRANSFER => true, // return web page CURLOPT_HEADER => false, // don't return headers CURLOPT_ENCODING => "UTF-8", // handle compressed CURLOPT_USERAGE...
Hey all, I'm trying to set a cookie for my phpBB forums from a MediaWiki login page. Using the hook after a login to the wiki is successful, I want to run a php script that sets the cookie. The script works when I run it independently or when I use GET , but for security reasons I want to POST to the script. For this I figured curl wo...
I have the following PHP code that uses cURL: $ch = curl_init(); curl_setopt($ch,CURLOPT_URL,"http://area51.stackexchange.com/users/flair/31.json"); curl_setopt($ch,CURLOPT_RETURNTRANSFER,1); $a_data = json_decode(curl_exec($ch)); echo curl_error($ch); I then get the following error when I try to access the page over HTTP: Fail...
Is there a way to detect in my script whether the request is coming from normal web browser or some script executing curl. I can see the headers and can distinguish with "User-Agent and other few headers" but in curl fake headers can be set, so i am not able to track the request. Please suggest me ways about identifying the curl or othe...
I have a server with different IPs assigned, how can I specifiy a different IP to be used by cURL? ...
<script type= "text/javascript"> /*<![CDATA[*/ $(document).ready(function(){ $('form.upform').submit(function() { $(".file").animate({"height": "toggle", "opacity": "toggle"}, "slow"); $(".loading").fadeIn("slow"); }); }); var max = <?=$settings['SET_MAX_UPLOAD'];?>; var count = 1; $(document).ready(function(){ $('.add...
How can I download page on this link http://www.kayak.com/s/search/air?ai=kayaksample&do=y&ft=ow&ns=n&cb=e&pa=1&l1=ZAG&t1=a&df=dmy&d1=4/10/2010&depart_flex=exact&r1=y&l2=LON&t2=a&d2=11/10/2010&return_flex&r2=y Link changes to short version (for example www.kayak.com/r/OcJd...
Hello <?php function query($url, $pfields = 0, $cookie = 0, $login = 0) { if($ch = curl_init($url)) { curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.9.1.5) Gecko/20091102 Firefox/3.9.0'); curl_setopt($ch, CURLOPT_HEADER, 1); if (!empty($pfields)) { ...
So, I am running a facebook application and I have to call FQL quite frequently. e.g. calling $fbObj->api_client->users_getStandardInfo() with the old facebookapi_php5_restlib However, I found it VERY VERY VERY SLOW to get the response back. I know that call actually use CURL connect to Facebook. So, is the CURL call slow in r...