Свойство | Type | Description | |
---|---|---|---|
$api | |||
$debugMode | |||
$error | |||
$password | |||
$session | Requests_Session | ||
$useragent | |||
$username |
Méthode | Description | |
---|---|---|
__construct ( $api ) : Wikimate | Create a new Wikimate object. | |
debugCurlConfig ( boolean $echo = false ) : mixed | Used to return or print the curl settings, but now prints an error and returns Wikimate::debugRequestsConfig(). | |
debugRequestsConfig ( boolean $echo = false ) : boolean | Get or print the Requests configuration. | |
delete ( array $array ) : array | Perfoms a delete query to the wiki API. | |
download ( string $url ) : mixed | Downloads data from the given URL. | |
edit ( array $array ) : array | Perfoms an edit query to the wiki API. | |
getError ( ) : mixed | Returns the latest error if there is one. | |
getFile ( string $filename ) : WikiFile | Returns a WikiFile object populated with the file data. | |
getPage ( string $title ) : WikiPage | Returns a WikiPage object populated with the page data. | |
login ( string $username, string $password, string $domain = null ) : boolean | Logs in to the wiki. | |
parse ( array $array ) : array | Performs a parse query to the wiki API. | |
query ( array $array ) : array | Performs a query to the wiki API with the given details. | |
setDebugMode ( boolean $b ) : Wikimate | Sets the debug mode. | |
upload ( array $array ) : array | Uploads a file to the wiki API. |
Méthode | Description | |
---|---|---|
initRequests ( ) : void | Set up a Requests_Session with appropriate user agent. |
public __construct ( $api ) : Wikimate | ||
Résultat | Wikimate |
public debugCurlConfig ( boolean $echo = false ) : mixed | ||
$echo | boolean | True to echo the configuration |
Résultat | mixed | Array of config if $echo is false, (boolean) true if echo is true |
public debugRequestsConfig ( boolean $echo = false ) : boolean | ||
$echo | boolean | Whether to echo the options |
Résultat | boolean | Options if $echo is false |
protected initRequests ( ) : void | ||
Résultat | void |
public setDebugMode ( boolean $b ) : Wikimate | ||
$b | boolean | True to turn debugging on |
Résultat | Wikimate | This object |