first commit

This commit is contained in:
root
2017-09-27 17:53:26 +02:00
commit a01e7fe597
139 changed files with 7890 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
<?php
class CommentLatestIdAPI extends ApiBase {
public function execute() {
$pageID = $this->getMain()->getVal( 'pageID' );
$commentsPage = new CommentsPage( $pageID, RequestContext::getMain() );
$result = $this->getResult();
$result->addValue( $this->getModuleName(), 'id', $commentsPage->getLatestCommentID() );
}
public function getAllowedParams() {
return array(
'pageID' => array(
ApiBase::PARAM_REQUIRED => true,
ApiBase::PARAM_TYPE => 'int'
)
);
}
}