PHP 인터페이스 seregazhuk\PinterestBot\Api\Contracts\HttpClient

파일 보기 프로젝트 열기: seregazhuk/php-pinterest-bot 0 사용 예제들

공개 메소드들

메소드 설명
cookie ( $name ) : mixed
cookies ( ) : array
execute ( string $url, string $postString = '', array $headers = [] ) : string Executes curl request.
getCookiesPath ( ) : string
getCurrentUrl ( ) : string Returns current url after all redirects
loadCookies ( string $username = '' ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient Load cookies for specified username
removeCookies ( ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
setCookiesPath ( string $path ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient Set directory to store all cookie files.
setOptions ( array $options ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient Set custom Curl options to override default
useProxy ( string $host, string $port, string $auth = null, string $type = null ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
useSocksProxy ( string $host, string $port, null $auth = null ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient

메소드 상세

cookies() 공개 메소드

public cookies ( ) : array
리턴 array

execute() 공개 메소드

Executes curl request.
public execute ( string $url, string $postString = '', array $headers = [] ) : string
$url string
$postString string
$headers array
리턴 string

getCookiesPath() 공개 메소드

public getCookiesPath ( ) : string
리턴 string

getCurrentUrl() 공개 메소드

Returns current url after all redirects
public getCurrentUrl ( ) : string
리턴 string

loadCookies() 공개 메소드

Load cookies for specified username
public loadCookies ( string $username = '' ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
$username string
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient

removeCookies() 공개 메소드

public removeCookies ( ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient

setCookiesPath() 공개 메소드

Set directory to store all cookie files.
public setCookiesPath ( string $path ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
$path string
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient

setOptions() 공개 메소드

Set custom Curl options to override default
public setOptions ( array $options ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
$options array
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient

useProxy() 공개 메소드

public useProxy ( string $host, string $port, string $auth = null, string $type = null ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
$host string '192.168.1.1'
$port string '12345'
$auth string Authentication string: 'username:password'
$type string HTTP|SOCKS
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient

useSocksProxy() 공개 메소드

public useSocksProxy ( string $host, string $port, null $auth = null ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient
$host string
$port string
$auth null
리턴 seregazhuk\PinterestBot\Api\Contracts\HttpClient