getOption() public method

Get a cURL session option.
public getOption ( integer $opt ) : string
$opt integer
return string
Exemplo n.º 1
0
 public function testSetAndGetOptions()
 {
     $c = new Curl('http://www.popphp.org/version', array(CURLOPT_RETURNTRANSFER => true));
     $c->setOption(CURLOPT_HEADER, false);
     $this->assertEquals(1, $c->getOption(CURLOPT_RETURNTRANSFER));
     $this->assertEquals(0, $c->getOption(CURLOPT_HEADER));
 }