Page MenuHomePhabricator
Paste P3948

(An Untitled Masterwork)
ActivePublic

Authored by Legoktm on Aug 31 2016, 7:49 AM.
legoktm@tin:/srv/mediawiki-staging/php-1.28.0-wmf.17/extensions$ ack-grep "EditPage" --php
ContentTranslation/ContentTranslation.hooks.php
194: * Hook: EditPage::showEditForm:initial
196: public static function newArticleCampaign( EditPage $newPage, OutputPage $out ) {
MobileFrontend/includes/skins/SkinMinerva.php
963: $menu['edit'] = $this->createEditPageAction();
988: protected function createEditPageAction() {
LiquidThreads/classes/View.php
514: $e = new EditPage( $article );
631: $e = new EditPage( $article );
744: $e = new EditPage( $article );
847: $e = new EditPage( $article );
1808: // as it would involve rewriting EditPage, which I do NOT intend to do.
2075: Hooks::run( 'EditPageBeforeEditToolbar', array( &$html ) );
LiquidThreads/classes/Hooks.php
306: * @param $editPage EditPage
LiquidThreads/api/ApiThreadAction.php
3:class ApiThreadAction extends ApiEditPage {
TemplateSandbox/TemplateSandbox.hooks.php
4: * Hook for EditPage::importFormData to parse our new form fields, and if
10: * @param EditPage $editpage
47: * @param EditPage $editpage
124: ' [[#' . EditPage::EDITFORM_ID . '|' . $wgLang->getArrow() . ' ' .
178: * Hook for EditPage::showStandardInputs:options to add our form fields to
181: * @param EditPage $editpage
TemplateSandbox/SpecialTemplateSandbox.php
106: if ( is_callable( 'EditPage::getPreviewLimitReport' ) ) {
108: EditPage::getPreviewLimitReport( $this->output ) ) );
EventLogging/includes/JsonSchemaHooks.php
61: * @param EditPage $editor
WikimediaMessages/WikimediaMessages.hooks.php
158: public static function onEditPageCopyrightWarning( $title, &$msg ) {
ProofreadPage/includes/index/EditProofreadIndexPage.php
23:class EditProofreadIndexPage extends EditPage {
ProofreadPage/includes/page/EditPagePage.php
7:use EditPage;
17:class EditPagePage extends EditPage {
49: * @see EditPage::isSectionEditSupported
56: * @see EditPage::isSupportedContentModel
65: * @see EditPage::showContentForm
75: * @see EditPage::showContentForm
143: * @see EditPage::getCheckBoxes
192: * @see EditPage::importContentFormData
209: * @see EditPage::internalAttemptSave
ProofreadPage/includes/page/PageSubmitAction.php
21: $editor = new EditPagePage( $this->page, $pagePage, Context::getDefaultContext() );
ProofreadPage/includes/page/PageEditAction.php
21: $editor = new EditPagePage( $this->page, $pagePage, Context::getDefaultContext() );
ProofreadPage/ProofreadPage.body.php
627: $ourStatus->value = EditPage::AS_HOOK_ERROR;
GlobalCssJs/GlobalCssJs.hooks.php
115: * @param EditPage $editPage
119: static function onEditPageshowEditForminitial( EditPage $editPage, OutputPage $output ) {
SemanticForms/includes/SF_AutoeditAPI.php
340: protected function setupEditPage( $targetContent ) {
354: $editor = new EditPage( $article );
412: Hooks::run( 'EditPage::showEditForm:initial', array( &$editor, &$wgOut ) );
432: protected function doStore( EditPage $editor ) {
476: case EditPage::AS_HOOK_ERROR_EXPECTED: // A hook function returned an error
481: Hooks::register('EditPageBeforeEditButtons', function( &$editor, &$buttons, &$tabindex ){
495: case EditPage::AS_CONTENT_TOO_BIG: // Content too big (> $wgMaxArticleSize)
496: case EditPage::AS_ARTICLE_WAS_DELETED: // article was deleted while editting and param wpRecreate == false or form was not posted
497: case EditPage::AS_CONFLICT_DETECTED: // (non-resolvable) edit conflict
498: case EditPage::AS_SUMMARY_NEEDED: // no edit summary given and the user has forceeditsummary set and the user is not editting in his own userspace or talkspace and wpIgnoreBlankSummary == false
499: case EditPage::AS_TEXTBOX_EMPTY: // user tried to create a new section without content
500: case EditPage::AS_MAX_ARTICLE_SIZE_EXCEEDED: // article is too big (> $wgMaxArticleSize), after merging in the new section
501: case EditPage::AS_END: // WikiPage::doEdit() was unsuccessfull
505: case EditPage::AS_HOOK_ERROR: // Article update aborted by a hook function
513:// case EditPage::AS_PARSE_ERROR: // can't parse content
518: case EditPage::AS_SUCCESS_NEW_ARTICLE: // Article successfully created
534: case EditPage::AS_SUCCESS_UPDATE: // Article successfully updated
562: case EditPage::AS_BLANK_ARTICLE: // user tried to create a blank page
571: case EditPage::AS_SPAM_ERROR: // summary contained spam according to one of the regexes in $wgSummarySpamRegex
580: case EditPage::AS_BLOCKED_PAGE_FOR_USER: // User is blocked from editting editor page
583: case EditPage::AS_IMAGE_REDIRECT_ANON: // anonymous user is not allowed to upload (User::isAllowed('upload') == false)
584: case EditPage::AS_IMAGE_REDIRECT_LOGGED: // logged in user is not allowed to upload (User::isAllowed('upload') == false)
587: case EditPage::AS_READ_ONLY_PAGE_ANON: // editor anonymous user is not allowed to edit editor page
588: case EditPage::AS_READ_ONLY_PAGE_LOGGED: // editor logged in user is not allowed to edit editor page
591: case EditPage::AS_READ_ONLY_PAGE: // wiki is in readonly mode (wfReadOnly() == true)
594: case EditPage::AS_RATE_LIMITED: // rate limiter for action 'edit' was tripped
597: case EditPage::AS_NO_CREATE_PERMISSION: // user tried to create editor page, but is not allowed to do that ( Title->usercan('create') == false )
992: $editor = $this->setupEditPage( $targetContent );
SemanticForms/includes/SF_Hooks.php
74: $GLOBALS['wgEditPageFrameOptions'] = 'SAMEORIGIN';
305: public static function showFormPreview( EditPage $editpage, WebRequest $request ) {
SemanticForms/includes/SF_FormUtils.php
99: // this code borrowed from /includes/EditPage.php
263: // Much of this function is based on MediaWiki's EditPage::showEditForm()
299: // based on MediaWiki's EditPage::getPreloadedText()
SemanticForms/includes/SF_FormPrinter.php
702: // $userCanEditPage = ( $wgUser->isAllowed( 'edit' ) && $this->mPageTitle->userCan( 'edit' ) );
709: $userCanEditPage = count( $permissionErrors ) == 0;
710: Hooks::run( 'sfUserCanEditPage', array( $this->mPageTitle, &$userCanEditPage ) );
713: if ( $is_query || $userCanEditPage ) {
718: // Based on code in MediaWiki's EditPage.php.
947: // borrowed from EditPage::showEditTools()
SemanticForms/includes/forminputs/SF_TextAreaInput.php
166: $editPage = new EditPage( $article );
SemanticForms/SemanticForms.php
148:$GLOBALS['wgHooks']['EditPage::importFormData'][] = 'SFHooks::showFormPreview';
264:$GLOBALS['wgEditPageFrameOptions'] = 'SAMEORIGIN';
Math/Math.hooks.php
391: static function onEditPageBeforeEditToolbar( &$toolbar ) {
Wikidata/extensions/Wikibase/repo/includes/EditEntity.php
772: * @note Keep in sync with logic in EditPage!
791: * @note Keep in sync with logic in EditPage!
Wikidata/extensions/Wikibase/repo/includes/Api/ResultBuilder.php
1114: // like core's ApiEditPage
Wikidata/extensions/Wikibase/repo/includes/Store/Sql/WikiPageEntityStore.php
323: * @see EditPage::userWasLastToEdit()
364: * @note keep in sync with logic in EditPage
Wikidata/extensions/Wikibase/repo/includes/Actions/EditEntityAction.php
446: * Generate standard summary input and label (wgSummary), compatible to EditPage.
Wikidata/extensions/Wikibase/repo/Wikibase.hooks.php
6:use ApiEditPage;
550: * This implementation causes the execution of ApiEditPage (action=edit) to fail
565: if ( $module instanceof ApiEditPage ) {
575: // trying to use ApiEditPage on an entity namespace
Wikidata/extensions/Wikibase/repo/tests/phpunit/includes/Api/EditPageTest.php
21: * @group EditPageTest
27:class EditPageTest extends WikibaseApiTestCase {
37: $item->setLabel( "en", "EditPageTest" );
40: $item->setLabel( "de", "EditPageTest" );
Wikidata/extensions/Wikibase/lib/includes/Store/EntityStore.php
104: * @see EditPage::userWasLastToEdit()
Wikidata/extensions/Wikibase/lib/tests/phpunit/MockRepository.php
565: * @see EditPage::userWasLastToEdit
Wikidata/vendor/composer/autoload_classmap.php
1302: 'Wikibase\\Test\\Repo\\Api\\EditPageTest' => $baseDir . '/extensions/Wikibase/repo/tests/phpunit/includes/Api/EditPageTest.php',
SpamBlacklist/SpamBlacklistHooks.php
65: // Always return true, EditPage will look at $status->isOk().
119: * @param $editPage EditPage
WikimediaEvents/WikimediaEventsHooks.php
375: * @see https://www.mediawiki.org/wiki/Manual:Hooks/EditPageBeforeConflictDiff
377: * @param EditPage &$editor
381: public static function onEditPageBeforeConflictDiff( &$editor, &$out ) {
UploadWizard/includes/CampaignHooks.php
126: * @param EditPage $editor
Translate/tag/PageTranslationHooks.php
389: * edit conflict if there wasn't tpSyntaxCheckForEditPage.
Translate/utils/TranslationHelpers.php
635: $jsEdit = TranslationEditPage::jsEdit( $target, $groupId, 'dialog' );
Translate/utils/MessageTable.php
193: $linkAttribs += TranslationEditPage::jsEdit( $title, $this->group->getId() );
Translate/utils/TranslationEditPage.php
15:class TranslationEditPage {
32: * @return TranslationEditPage
Translate/specials/SpecialTranslate.php
61: $editpage = TranslationEditPage::newFromRequest( $request );
Translate/TranslateEditAddons.php
22: public static function suppressIntro( EditPage $editPage ) {
63: * Hook: EditPage::showEditForm:initial
65: public static function addTools( EditPage $object ) {
79: * Hook: EditPageBeforeEditButtons
81: public static function buttonHack( EditPage $editpage, &$buttons, $tabindex ) {
127: * @param EditPage $editpage
130: private static function editBoxes( EditPage $editpage ) {
Translate/Translate.php
101:$wgHooks['EditPage::showEditForm:initial'][] = 'TranslateEditAddons::addTools';
104:$wgHooks['EditPageBeforeEditButtons'][] = 'TranslateEditAddons::buttonHack';
Translate/Autoload.php
105:$al['TranslationEditPage'] = "$dir/utils/TranslationEditPage.php";
MoodBar/MoodBar.hooks.php
109: if ( class_exists('EditPageTracking') ) {
110: return ((bool)EditPageTracking::getFirstEditPage( $skin->getUser() ) );
MassMessage/includes/SpecialMassMessage.php
150: $m['message']['help'] = EditPage::getCopyrightWarning( $this->getPageTitle( false ), 'parse' );
263: * The preview generation code was hacked up from EditPage.php
285: // Parser stuff. Taken from EditPage::getPreviewText()
292: // Hooks not being run: EditPageGetPreviewContent, EditPageGetPreviewText
MassMessage/includes/SpecialEditMassMessageList.php
104: // Edit notices; modified from EditPage::showHeader()
111: // Protection warnings; modified from EditPage::showHeader()
212: return EditPage::getCopyrightWarning( $this->title, 'parse' );
ConfirmEdit/includes/ConfirmEditHooks.php
82: static function confirmEditPage( $editpage, $buttons, $tabindex ) {
221: * @param EditPage $editor
227: public static function onAlternateEditPreview( EditPage $editor, &$content, &$html, &$po ) {
ConfirmEdit/SimpleCaptcha/Captcha.php
180: * Show error message for missing or incorrect captcha on EditPage.
181: * @param EditPage $editPage
199: * @param EditPage $editPage
909: $status->value = EditPage::AS_HOOK_ERROR_EXPECTED;
1064: return $module instanceof ApiEditPage || $module instanceof ApiCreateAccount;
WikiEditor/WikiEditor.hooks.php
173: * EditPage::showEditForm:initial hook
177: * @param EditPage $editPage the current EditPage object.
231: * EditPage::showEditForm:fields hook
235: * @param EditPage $editPage the current EditPage object.
265: * EditPageBeforeEditToolbar hook
272: public static function EditPageBeforeEditToolbar( &$toolbar ) {
395: * This is attached to the MediaWiki 'EditPage::attemptSave' hook.
397: * @param EditPage $editPage
401: public static function editPageAttemptSave( EditPage $editPage ) {
416: * This is attached to the MediaWiki 'EditPage::attemptSave:after' hook.
418: * @param EditPage $editPage
422: public static function editPageAttemptSaveAfter( EditPage $editPage, Status $status ) {
439: if ( $status->value === EditPage::AS_CONFLICT_DETECTED ) {
441: } elseif ( $status->value === EditPage::AS_ARTICLE_WAS_DELETED ) {
TemplateData/TemplateData.hooks.php
84: // Specify format the same way the API and EditPage do to avoid extra parsing
102: * @param EditPage $editPage
106: public static function onEditPage( $editPage, $output ) {
Scribunto/Scribunto.php
71:$wgHooks['EditPageBeforeEditChecks'][] = 'ScribuntoHooks::beforeEditChecks';
72:$wgHooks['EditPage::showReadOnlyForm:initial'][] = 'ScribuntoHooks::showReadOnlyFormInitial';
73:$wgHooks['EditPageBeforeEditButtons'][] = 'ScribuntoHooks::beforeEditButtons';
Scribunto/common/Hooks.php
325: * EditPageBeforeEditChecks hook
327: * @param EditPage $editor
332: public static function beforeEditChecks( EditPage &$editor, &$checkboxes, &$tabindex ) {
342: * EditPage::showReadOnlyForm:initial hook
344: * @param EditPage $editor
347: public static function showReadOnlyFormInitial( EditPage $editor, OutputPage $output ) {
356: * EditPageBeforeEditButtons hook
358: * @param EditPage $editor
363: public static function beforeEditButtons( EditPage &$editor, array &$buttons, &$tabindex ) {
371: * @param EditPage $editor
377: public static function validateScript( EditPage $editor, $text, &$error, $summary ) {
TitleBlacklist/TitleBlacklist.hooks.php
245: * @param $editor EditPage
FlaggedRevs/backend/FlaggedRevs.hooks.php
391: # Get edit timestamp. Existance already validated by EditPage.php.
FlaggedRevs/frontend/FlaggedRevsUI.setup.php
39: $hooks['EditPage::showEditForm:initial'][] = 'FlaggedRevsUIHooks::addToEditView';
42: $hooks['EditPageBeforeEditButtons'][] = 'FlaggedRevsUIHooks::onBeforeEditButtons';
44: $hooks['EditPageBeforeEditChecks'][] = 'FlaggedRevsUIHooks::addReviewCheck';
45: $hooks['EditPage::showEditForm:fields'][] = 'FlaggedRevsUIHooks::addRevisionIDField';
47: $hooks['EditPageNoSuchSection'][] = 'FlaggedRevsUIHooks::onNoSuchSection';
FlaggedRevs/frontend/FlaggablePageView.php
922: // HACK: EditPage invokes addToEditView() before this function, so $this->noticesDone
923: // will only be true if we're being called by EditPage, in which case we need to do nothing
929: // HACK fake EditPage
930: $editPage = new EditPage( new Article( $title, $oldid ) );
970: public function addToEditView( EditPage $editPage ) {
1076: public function addToNoSuchSection( EditPage $editPage, &$s ) {
1776: $extraQuery .= wfArrayToCgi( $params ); // note: EditPage will add initial "&"
1785: public function changeSaveButton( EditPage $editPage, array &$buttons ) {
1810: * @param EditPage $editPage
1813: protected function editWillRequireReview( EditPage $editPage ) {
1826: * @param EditPage $editPage
1829: protected function editRequiresReview( EditPage $editPage ) {
1841: * @param EditPage $editPage
1844: protected function editWillBeAutoreviewed( EditPage $editPage ) {
1873: public function addReviewCheck( EditPage $editPage, array &$checkboxes, &$tabindex ) {
1922: public function addRevisionIDField( EditPage $editPage, OutputPage $out ) {
1935: * @param EditPage $editPage
1939: protected static function getBaseRevId( EditPage $editPage, WebRequest $request ) {
1968: * @param EditPage $editPage
1972: protected static function getAltBaseRevId( EditPage $editPage, WebRequest $request ) {
VisualEditor/VisualEditorDataModule.php
52: // Copyright warning (based on EditPage::getCopyrightWarning)
62: // EditPage supports customisation based on title, we can't support that
64: Hooks::run( 'EditPageCopyrightWarning', [ $title, &$copywarnMsgArgs ] );
VisualEditor/ApiVisualEditor.php
480: // HACK of course this code is partly duplicated from EditPage.php :(
517: // HACK: Build a fake EditPage so we can get checkboxes from it
519: $ep = new EditPage( $article );
VisualEditor/VisualEditor.hooks.php
390: * @param $editPage EditPage
394: public static function onEditPageShowEditFormFields( EditPage $editPage, OutputPage $output ) {