1--TEST-- 2Test curl_getinfo() function with CURLINFO_HTTP_CODE parameter 3--CREDITS-- 4Jean-Marc Fontaine <jmf@durcommefaire.net> 5--EXTENSIONS-- 6curl 7--FILE-- 8<?php 9 include 'server.inc'; 10 $host = curl_cli_server_start(); 11 12 $url = "{$host}/get.inc?test="; 13 $ch = curl_init(); 14 curl_setopt($ch, CURLOPT_URL, $url); 15 curl_exec($ch); 16 var_dump(curl_getinfo($ch, CURLINFO_HTTP_CODE)); 17 curl_close($ch); 18?> 19--EXPECT-- 20Hello World! 21Hello World!int(200) 22