[ Index ]

PHP Cross Reference of MediaWiki-1.24.0

title

Body

[close]

/includes/api/ -> ApiDelete.php (summary)

Created on Jun 30, 2007 Copyright © 2007 Roan Kattouw "<Firstname>.<Lastname>@gmail.com"

File Size: 248 lines (7 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

ApiDelete:: (12 methods):
  execute()
  getPermissionsError()
  delete()
  deleteFile()
  mustBePosted()
  isWriteMode()
  getAllowedParams()
  getParamDescription()
  getDescription()
  needsToken()
  getExamples()
  getHelpUrls()


Class: ApiDelete  - X-Ref

API module that facilitates deleting pages. The API equivalent of action=delete.
Requires API write mode to be enabled.

execute()   X-Ref
Extracts the title, token, and reason from the request parameters and invokes
the local delete() function with these as arguments. It does not make use of
the delete function specified by Article.php. If the deletion succeeds, the
details of the article deleted and the reason for deletion are added to the
result object.


getPermissionsError( $title, $user, $token )   X-Ref

param: Title $title
param: User $user User doing the action
param: string $token
return: array

delete( Page $page, User $user, $token, &$reason = null )   X-Ref
We have our own delete() function, since Article.php's implementation is split in two phases

param: Page|WikiPage $page Page or WikiPage object to work on
param: User $user User doing the action
param: string $token Delete token (same as edit token)
param: string|null $reason Reason for the deletion. Autogenerated if null
return: Status|array

deleteFile( Page $page, User $user, $token, $oldimage,&$reason = null, $suppress = false)   X-Ref

param: Page $page Object to work on
param: User $user User doing the action
param: string $token Delete token (same as edit token)
param: string $oldimage Archive name
param: string $reason Reason for the deletion. Autogenerated if null.
param: bool $suppress Whether to mark all deleted versions as restricted
return: Status|array

mustBePosted()   X-Ref
No description

isWriteMode()   X-Ref
No description

getAllowedParams()   X-Ref
No description

getParamDescription()   X-Ref
No description

getDescription()   X-Ref
No description

needsToken()   X-Ref
No description

getExamples()   X-Ref
No description

getHelpUrls()   X-Ref
No description



Generated: Fri Nov 28 14:03:12 2014 Cross-referenced by PHPXref 0.7.1