Initial commit: Open sourcing all of the Maple Open Technologies code.
This commit is contained in:
commit
755d54a99d
2010 changed files with 448675 additions and 0 deletions
82
native/wordpress/maplepress-plugin/maplepress-plugin.php
Normal file
82
native/wordpress/maplepress-plugin/maplepress-plugin.php
Normal file
|
|
@ -0,0 +1,82 @@
|
|||
<?php
|
||||
/**
|
||||
* Plugin Name: MaplePress
|
||||
* Plugin URI: https://codeberg.org/mapleopentech/monorepo/src/branch/main/native/wordpress/maplepress-plugin
|
||||
* Description: Fast, scalable search for WordPress - Offloads search processing to the cloud for lightning-fast results without slowing down your server
|
||||
* Version: 1.0.0
|
||||
* Requires at least: 6.0
|
||||
* Requires PHP: 7.4
|
||||
* Author: Maple Open Technologies
|
||||
* Author URI: https://mapleopentech.io
|
||||
* License: GPL-2.0+
|
||||
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt
|
||||
* Text Domain: maplepress
|
||||
* Domain Path: /languages
|
||||
*
|
||||
* @package MaplePress
|
||||
*/
|
||||
|
||||
// If this file is called directly, abort.
|
||||
if (!defined("WPINC")) {
|
||||
die();
|
||||
}
|
||||
|
||||
/**
|
||||
* Current plugin version.
|
||||
*/
|
||||
define("MAPLEPRESS_VERSION", "1.0.0");
|
||||
|
||||
/**
|
||||
* Plugin file path.
|
||||
*/
|
||||
define("MAPLEPRESS_PLUGIN_FILE", __FILE__);
|
||||
|
||||
/**
|
||||
* Plugin directory path.
|
||||
*/
|
||||
define("MAPLEPRESS_PLUGIN_DIR", plugin_dir_path(__FILE__));
|
||||
|
||||
/**
|
||||
* Plugin directory URL.
|
||||
* Use set_url_scheme() to ensure correct protocol (HTTP/HTTPS) based on current request.
|
||||
* This prevents mixed content issues when site is served over HTTPS.
|
||||
*/
|
||||
define("MAPLEPRESS_PLUGIN_URL", set_url_scheme(plugin_dir_url(__FILE__)));
|
||||
|
||||
/**
|
||||
* The code that runs during plugin activation.
|
||||
*/
|
||||
function activate_maplepress()
|
||||
{
|
||||
require_once MAPLEPRESS_PLUGIN_DIR .
|
||||
"includes/class-maplepress-activator.php";
|
||||
MaplePress_Activator::activate();
|
||||
}
|
||||
|
||||
/**
|
||||
* The code that runs during plugin deactivation.
|
||||
*/
|
||||
function deactivate_maplepress()
|
||||
{
|
||||
require_once MAPLEPRESS_PLUGIN_DIR .
|
||||
"includes/class-maplepress-deactivator.php";
|
||||
MaplePress_Deactivator::deactivate();
|
||||
}
|
||||
|
||||
register_activation_hook(__FILE__, "activate_maplepress");
|
||||
register_deactivation_hook(__FILE__, "deactivate_maplepress");
|
||||
|
||||
/**
|
||||
* The core plugin class.
|
||||
*/
|
||||
require MAPLEPRESS_PLUGIN_DIR . "includes/class-maplepress.php";
|
||||
|
||||
/**
|
||||
* Begins execution of the plugin.
|
||||
*/
|
||||
function run_maplepress()
|
||||
{
|
||||
$plugin = new MaplePress();
|
||||
$plugin->run();
|
||||
}
|
||||
run_maplepress();
|
||||
Loading…
Add table
Add a link
Reference in a new issue