index.php 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. /**
  3. * This is the main web entry point for MediaWiki.
  4. *
  5. * If you are reading this in your web browser, your server is probably
  6. * not configured correctly to run PHP applications!
  7. *
  8. * See the README, INSTALL, and UPGRADE files for basic setup instructions
  9. * and pointers to the online documentation.
  10. *
  11. * https://www.mediawiki.org/wiki/Special:MyLanguage/MediaWiki
  12. *
  13. * ----------
  14. *
  15. * This program is free software; you can redistribute it and/or modify
  16. * it under the terms of the GNU General Public License as published by
  17. * the Free Software Foundation; either version 2 of the License, or
  18. * (at your option) any later version.
  19. *
  20. * This program is distributed in the hope that it will be useful,
  21. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  22. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  23. * GNU General Public License for more details.
  24. *
  25. * You should have received a copy of the GNU General Public License along
  26. * with this program; if not, write to the Free Software Foundation, Inc.,
  27. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  28. * http://www.gnu.org/copyleft/gpl.html
  29. *
  30. * @file
  31. */
  32. define( 'MW_ENTRY_POINT', 'index' );
  33. // Bail on old versions of PHP, or if composer has not been run yet to install
  34. // dependencies. Using dirname( __FILE__ ) here because __DIR__ is PHP5.3+.
  35. // phpcs:ignore MediaWiki.Usage.DirUsage.FunctionFound
  36. require_once dirname( __FILE__ ) . '/includes/PHPVersionCheck.php';
  37. wfEntryPointCheck( 'html', dirname( $_SERVER['SCRIPT_NAME'] ) );
  38. require __DIR__ . '/includes/WebStart.php';
  39. $mediaWiki = new MediaWiki();
  40. $mediaWiki->run();