MediaWiki
REL1_24
|
Special page outputs information on sourcing a book with a particular ISBN The parser creates links to this page when dealing with ISBNs in wikitext. More...
Public Member Functions | |
__construct () | |
Constructor. | |
execute ($isbn) | |
Show the special page. | |
Static Public Member Functions | |
static | isValidISBN ($isbn) |
Returns whether a given ISBN (10 or 13) is valid. | |
Protected Member Functions | |
getGroupName () | |
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'. | |
Private Member Functions | |
makeForm () | |
Generate a form to allow users to enter an ISBN. | |
makeListItem ($label, $url) | |
Format a book source list item. | |
showList () | |
Determine where to get the list of book sources from, format and output them. | |
Static Private Member Functions | |
static | cleanIsbn ($isbn) |
Trim ISBN and remove characters which aren't required. | |
Private Attributes | |
$isbn = '' | |
ISBN passed to the page, if any. |
Special page outputs information on sourcing a book with a particular ISBN The parser creates links to this page when dealing with ISBNs in wikitext.
Definition at line 32 of file SpecialBooksources.php.
Constructor.
Definition at line 41 of file SpecialBooksources.php.
static SpecialBookSources::cleanIsbn | ( | $ | isbn | ) | [static, private] |
Trim ISBN and remove characters which aren't required.
string | $isbn | Unclean ISBN |
Definition at line 110 of file SpecialBooksources.php.
References $isbn.
Referenced by execute(), and isValidISBN().
SpecialBookSources::execute | ( | $ | isbn | ) |
Show the special page.
string | $isbn | ISBN passed as a subpage parameter |
Reimplemented from SpecialPage.
Definition at line 50 of file SpecialBooksources.php.
References $isbn, cleanIsbn(), SpecialPage\getOutput(), SpecialPage\getRequest(), makeForm(), SpecialPage\outputHeader(), SpecialPage\setHeaders(), and showList().
SpecialBookSources::getGroupName | ( | ) | [protected] |
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.
Reimplemented from SpecialPage.
Definition at line 202 of file SpecialBooksources.php.
static SpecialBookSources::isValidISBN | ( | $ | isbn | ) | [static] |
Returns whether a given ISBN (10 or 13) is valid.
True indicates validity.
string | $isbn | ISBN passed for check |
Definition at line 71 of file SpecialBooksources.php.
References $isbn, and cleanIsbn().
SpecialBookSources::makeForm | ( | ) | [private] |
Generate a form to allow users to enter an ISBN.
Definition at line 119 of file SpecialBooksources.php.
References $form, array(), Html\closeElement(), Html\element(), SpecialPage\getPageTitle(), Html\hidden(), Xml\inputLabel(), SpecialPage\msg(), Html\openElement(), Xml\submitButton(), text, and wfScript().
Referenced by execute().
SpecialBookSources::makeListItem | ( | $ | label, |
$ | url | ||
) | [private] |
Format a book source list item.
string | $label | Book source label |
string | $url | Book source URL |
Definition at line 195 of file SpecialBooksources.php.
References array(), Html\element(), and Html\rawElement().
Referenced by showList().
SpecialBookSources::showList | ( | ) | [private] |
Determine where to get the list of book sources from, format and output them.
MWException |
Definition at line 150 of file SpecialBooksources.php.
References $content, $rev, $title, $wgContLang, array(), as, content, SpecialPage\getOutput(), global, in, language, list, makeListItem(), Title\makeTitleSafe(), SpecialPage\msg(), Revision\newFromTitle(), IDBAccessObject\READ_NORMAL, and wfRunHooks().
Referenced by execute().
SpecialBookSources::$isbn = '' [private] |
ISBN passed to the page, if any.
Definition at line 36 of file SpecialBooksources.php.
Referenced by cleanIsbn(), execute(), and isValidISBN().