Index: trunk/extensions/LiquidThreads/i18n/Lqt.i18n.php |
— | — | @@ -295,6 +295,7 @@ |
296 | 296 | |
297 | 297 | // Automatic summaries |
298 | 298 | 'lqt-newpost-summary' => 'New thread: $1', |
| 299 | + 'lqt-newpost-defaultbody-user-submitted-empty-textbody' => "<!-- thread subject $1 -->''Please enter your text for this thread. You should delete this line then.''", |
299 | 300 | 'lqt-reply-summary' => 'Reply to [[$2|$1]]', |
300 | 301 | |
301 | 302 | // Talk page history |
Index: trunk/extensions/LiquidThreads/api/ApiThreadAction.php |
— | — | @@ -222,7 +222,7 @@ |
223 | 223 | } |
224 | 224 | |
225 | 225 | public function actionNewThread( $threads, $params ) { |
226 | | - global $wgUser; |
| 226 | + global $wgUser,$wgOut; |
227 | 227 | |
228 | 228 | // Validate talkpage parameters |
229 | 229 | if ( !count( $params['talkpage'] ) ) { |
— | — | @@ -262,7 +262,9 @@ |
263 | 263 | |
264 | 264 | // Check for text |
265 | 265 | if ( empty( $params['text'] ) ) { |
266 | | - $this->dieUsage( 'You must include text in your post', 'no-text' ); |
| 266 | + // $this->dieUsage( 'You must include text in your post', 'no-text' ); |
| 267 | + // FIXME: add an "edit post" link as second parameter $2 to the text |
| 268 | + $params['text'] = wfMsgForContent( 'lqt-newpost-defaultbody-user-submitted-empty-textbody', $subject ) ; |
267 | 269 | } |
268 | 270 | $text = $params['text']; |
269 | 271 | |