MediaWiki REL1_32
|
Public Member Functions | |
__construct ( $parser) | |
extractOptions ( $text) | |
Extract options from a blob of text. | |
getCommentForm () | |
Generate new section form. | |
getCreateForm () | |
Generate create page form. | |
getMoveForm () | |
Generate move page form. | |
getSearchForm ( $type) | |
Generate search form. | |
getSearchForm2 () | |
Generate search form version 2. | |
isValidColor ( $color) | |
Do a security check on the bgcolor parameter. | |
render () | |
Private Member Functions | |
bgColorStyle () | |
getEditActionArgs () | |
Returns the action name and value to use in inputboxes which redirects to edit pages. | |
getLinebreakClasses () | |
Get common classes, that could be added and depend on, if a line break between a button and an input field is added or not. | |
languageConvert ( $text) | |
For compatability with pre T119158 behaviour. | |
shouldUseVE () | |
Returns true, if the VisualEditor is requested from the inputbox wikitext definition and if the VisualEditor extension is actually installed or not, false otherwise. | |
Private Attributes | |
$mBGColor = 'transparent' | |
$mBR = 'yes' | |
$mButtonLabel = '' | |
$mDefaultText = '' | |
$mDir = '' | |
$mEditIntro = null | |
$mFullTextButton = '' | |
$mHidden = '' | |
$mID = '' | |
$mInline = false | |
$mLabelText = '' | |
$mMinor = null | |
$mNamespaces = '' | |
$mNosummary = null | |
$mPage = '' | |
$mParser | |
$mPlaceholderText = '' | |
$mPrefix = '' | |
$mPreload = null | |
$mPreloadparams = null | |
$mSearchButtonLabel = '' | |
$mSearchFilter = '' | |
$mSummary = null | |
$mTour = '' | |
$mType = '' | |
$mUseVE = null | |
$mWidth = 50 | |
InputBox class.
Definition at line 12 of file InputBox.php.
InputBox::__construct | ( | $parser | ) |
|
private |
Definition at line 691 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), getSearchForm(), and getSearchForm2().
InputBox::extractOptions | ( | $text | ) |
Extract options from a blob of text.
string | $text | Tag contents |
Definition at line 592 of file InputBox.php.
References $line, $name, $options, $value, isValidColor(), languageConvert(), list, and true.
InputBox::getCommentForm | ( | ) |
Generate new section form.
Definition at line 522 of file InputBox.php.
References $mBR, $mDefaultText, $mDir, $mPlaceholderText, $mWidth, $wgScript, bgColorStyle(), getEditActionArgs(), getLinebreakClasses(), and wfMessage().
Referenced by render().
InputBox::getCreateForm | ( | ) |
Generate create page form.
Definition at line 376 of file InputBox.php.
References $mBR, $mDefaultText, $mDir, $mPlaceholderText, $mWidth, $wgScript, bgColorStyle(), getEditActionArgs(), getLinebreakClasses(), and wfMessage().
Referenced by render().
|
private |
Returns the action name and value to use in inputboxes which redirects to edit pages.
Decides, if the link should redirect to VE edit page (veaction=edit) or to wikitext editor (action=edit).
Definition at line 99 of file InputBox.php.
References $args, and shouldUseVE().
Referenced by getCommentForm(), and getCreateForm().
|
private |
Get common classes, that could be added and depend on, if a line break between a button and an input field is added or not.
Definition at line 121 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), and getSearchForm().
InputBox::getMoveForm | ( | ) |
Generate move page form.
Definition at line 465 of file InputBox.php.
References $mBR, $mDefaultText, $mDir, $mPlaceholderText, $mWidth, $wgScript, bgColorStyle(), getLinebreakClasses(), and wfMessage().
Referenced by render().
InputBox::getSearchForm | ( | $type | ) |
Generate search form.
string | $type |
Definition at line 130 of file InputBox.php.
References $mBR, $mDefaultText, $mDir, $mPlaceholderText, $mWidth, $namespaces, $type, $wgContLang, $wgNamespaceAliases, bgColorStyle(), getLinebreakClasses(), wfMessage(), and wfRandom().
Referenced by render().
InputBox::getSearchForm2 | ( | ) |
Generate search form version 2.
Definition at line 298 of file InputBox.php.
References $mDir, $mID, $mWidth, bgColorStyle(), wfMessage(), and wfRandom().
Referenced by render().
InputBox::isValidColor | ( | $color | ) |
Do a security check on the bgcolor parameter.
string | $color |
Definition at line 676 of file InputBox.php.
References color.
Referenced by extractOptions().
|
private |
For compatability with pre T119158 behaviour.
If a field that is going to be used as an attribute and it contains "-{" in it, run it through language converter.
Its not really clear if it would make more sense to always convert instead of only if -{ is present. This function just more or less restores the previous accidental behaviour.
Definition at line 722 of file InputBox.php.
References $lang.
Referenced by extractOptions().
InputBox::render | ( | ) |
Definition at line 63 of file InputBox.php.
References getCommentForm(), getCreateForm(), getMoveForm(), getSearchForm(), getSearchForm2(), text, and wfMessage().
|
private |
Returns true, if the VisualEditor is requested from the inputbox wikitext definition and if the VisualEditor extension is actually installed or not, false otherwise.
Definition at line 704 of file InputBox.php.
References ExtensionRegistry\getInstance().
Referenced by getEditActionArgs().
|
private |
Definition at line 30 of file InputBox.php.
|
private |
Definition at line 27 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), and getSearchForm().
|
private |
Definition at line 31 of file InputBox.php.
|
private |
Definition at line 28 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), and getSearchForm().
|
private |
Definition at line 40 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), getSearchForm(), and getSearchForm2().
|
private |
Definition at line 21 of file InputBox.php.
|
private |
Definition at line 33 of file InputBox.php.
|
private |
Definition at line 35 of file InputBox.php.
|
private |
Definition at line 37 of file InputBox.php.
Referenced by getSearchForm2().
|
private |
Definition at line 38 of file InputBox.php.
|
private |
Definition at line 34 of file InputBox.php.
|
private |
Definition at line 25 of file InputBox.php.
|
private |
Definition at line 36 of file InputBox.php.
|
private |
Definition at line 24 of file InputBox.php.
|
private |
Definition at line 26 of file InputBox.php.
|
private |
Definition at line 16 of file InputBox.php.
|
private |
Definition at line 29 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), and getSearchForm().
|
private |
Definition at line 39 of file InputBox.php.
|
private |
Definition at line 19 of file InputBox.php.
|
private |
Definition at line 20 of file InputBox.php.
|
private |
Definition at line 32 of file InputBox.php.
|
private |
Definition at line 41 of file InputBox.php.
|
private |
Definition at line 23 of file InputBox.php.
|
private |
Definition at line 42 of file InputBox.php.
|
private |
Definition at line 17 of file InputBox.php.
|
private |
Definition at line 22 of file InputBox.php.
|
private |
Definition at line 18 of file InputBox.php.
Referenced by getCommentForm(), getCreateForm(), getMoveForm(), getSearchForm(), and getSearchForm2().