From abd979818adec33feab128e4c433bd8dbf3344f4 Mon Sep 17 00:00:00 2001 From: umherirrender Date: Sat, 28 Apr 2012 20:59:01 +0200 Subject: [PATCH] add hints to description of action=edit add a hint to appendtext about section=new. I have seen, that people build up the new header by itself and concat that with the section text. It is easy to use section=new. Feel free to change my english, if you think, that is not good worded. Change-Id: I0642d496441c8fd375e8cb5dc383124b9ac25235 --- includes/api/ApiEditPage.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/includes/api/ApiEditPage.php b/includes/api/ApiEditPage.php index 290c5dff23..b45f351b51 100644 --- a/includes/api/ApiEditPage.php +++ b/includes/api/ApiEditPage.php @@ -471,14 +471,14 @@ class ApiEditPage extends ApiBase { 'sectiontitle' => 'The title for a new section', 'text' => 'Page content', 'token' => array( 'Edit token. You can get one of these through prop=info.', - 'The token should always be sent as the last parameter, or at least, after the text parameter' + "The token should always be sent as the last parameter, or at least, after the {$p}text parameter" ), - 'summary' => 'Edit summary. Also section title when section=new', + 'summary' => "Edit summary. Also section title when {$p}section=new and {$p}sectiontitle is not set", 'minor' => 'Minor edit', 'notminor' => 'Non-minor edit', 'bot' => 'Mark this edit as bot', 'basetimestamp' => array( 'Timestamp of the base revision (obtained through prop=revisions&rvprop=timestamp).', - 'Used to detect edit conflicts; leave unset to ignore conflicts.' + 'Used to detect edit conflicts; leave unset to ignore conflicts' ), 'starttimestamp' => array( 'Timestamp when you obtained the edit token.', 'Used to detect edit conflicts; leave unset to ignore conflicts' @@ -492,7 +492,8 @@ class ApiEditPage extends ApiBase { 'md5' => array( "The MD5 hash of the {$p}text parameter, or the {$p}prependtext and {$p}appendtext parameters concatenated.", 'If set, the edit won\'t be done unless the hash is correct' ), 'prependtext' => "Add this text to the beginning of the page. Overrides {$p}text", - 'appendtext' => "Add this text to the end of the page. Overrides {$p}text", + 'appendtext' => array( "Add this text to the end of the page. Overrides {$p}text.", + "Use {$p}section=new to append a new section" ), 'undo' => "Undo this revision. Overrides {$p}text, {$p}prependtext and {$p}appendtext", 'undoafter' => 'Undo all revisions from undo to this one. If not set, just undo one revision', 'redirect' => 'Automatically resolve redirects', -- 2.20.1