3 * A Special Page sample that can be included on a wikipage like
4 * {{Special:Includable}} as well as being accessed on [[Special:Includable]]
9 * @author Ævar Arnfjörð Bjarmason <avarab@gmail.com>
10 * @author Niklas Laxström
11 * @copyright Copyright © 2005, Ævar Arnfjörð Bjarmason
12 * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
15 $wgExtensionCredits['specialpage'][] = array(
17 'name' => 'Includable',
18 'description' => 'a sample includable Special Page',
19 'author' => 'Ævar Arnfjörð Bjarmason'
22 $wgSpecialPages['Includable'] = 'SpecialIncludable';
24 class SpecialIncludable
extends IncludableSpecialPage
{
26 public function __construct() {
27 parent
::__construct( 'Includable' );
33 public function execute( $par = null ) {
36 if ( $this->including() )
37 $out = "I'm being included";
39 $out = "I'm being viewed as a Special Page";
43 $wgOut->addWikiText( $out );