PluginProbe
SureCart – Ecommerce Made Easy For Selling Physical Products, Digital Downloads, Subscriptions, Donations, & Payments / 3.0.0-RC2
SureCart – Ecommerce Made Easy For Selling Physical Products, Digital Downloads, Subscriptions, Donations, & Payments v3.0.0-RC2
4.7.2 4.7.1 4.7.0 4.6.6 4.6.5 4.6.4 4.6.3 4.6.2 4.6.1 4.6.0 4.5.1 4.5.0 4.4.2 4.4.1 4.4.0 4.3.3 4.3.2 4.3.1 4.3.0 4.2.3 4.2.2 4.2.1 1.0.3 1.0.4 1.0.5 All 281 releases
surecart / surecart.php
surecart.php
67 lines 2.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Plugin Name: SureCart
4 * Plugin URI: https://surecart.com/
5 * Description: A simple yet powerful headless e-commerce platform designed to grow your business with effortlessly selling online.
6 * Version: 3.0.0-RC2
7 * Requires at least: 6.2
8 * Requires PHP: 7.4
9 * Author: SureCart
10 * Author URI: https://surecart.com
11 * License: GPL-2.0-only
12 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
13 * Text Domain: surecart
14 * Domain Path: /languages
15 *
16 * YOU SHOULD NORMALLY NOT NEED TO ADD ANYTHING HERE - any custom functionality unrelated
17 * to bootstrapping the theme should go into a service provider or a separate helper file
18 * (refer to the directory structure in README.md).
19 *
20 * @package SureCart
21 */
22
23 if ( ! defined( 'ABSPATH' ) ) {
24 exit;
25 }
26
27 define( 'SURECART_PLUGIN_FILE', __FILE__ );
28 define( 'SURECART_PLUGIN_DIR', __DIR__ );
29
30 define( 'SURECART_PLUGIN_DIR_NAME', dirname( plugin_basename( SURECART_PLUGIN_FILE ) ) );
31 define( 'SURECART_LANGUAGE_DIR', __DIR__ . DIRECTORY_SEPARATOR . 'languages' );
32 define( 'SURECART_DIST_DIR', __DIR__ . DIRECTORY_SEPARATOR . 'dist' );
33 define( 'SURECART_VENDOR_DIR', __DIR__ . DIRECTORY_SEPARATOR . 'vendor' );
34 define( 'SURECART_PLUGIN_BASE', plugin_basename( SURECART_PLUGIN_FILE ) );
35
36 // define host url.
37 if ( ! defined( 'SURECART_APP_URL' ) ) {
38 define( 'SURECART_APP_URL', 'https://app.surecart.com' );
39 }
40 if ( ! defined( 'SURECART_REPORTS_URL' ) ) {
41 define( 'SURECART_REPORTS_URL', 'https://app.surecart.com/reports/' );
42 }
43 if ( ! defined( 'SURECART_API_URL' ) ) {
44 define( 'SURECART_API_URL', 'https://api.surecart.com' );
45 }
46 if ( ! defined( 'SURECART_JS_URL' ) ) {
47 define( 'SURECART_JS_URL', 'https://js.surecart.com' );
48 }
49 if ( ! defined( 'SURECART_CDN_IMAGE_BASE' ) ) {
50 define( 'SURECART_CDN_IMAGE_BASE', 'https://surecart.com/cdn-cgi/image' );
51 }
52
53 // Load composer dependencies.
54 if ( file_exists( SURECART_VENDOR_DIR . DIRECTORY_SEPARATOR . 'autoload.php' ) ) {
55 require_once SURECART_VENDOR_DIR . DIRECTORY_SEPARATOR . 'autoload.php';
56 }
57
58 // Load helpers.
59 require_once __DIR__ . DIRECTORY_SEPARATOR . 'app' . DIRECTORY_SEPARATOR . 'src' . DIRECTORY_SEPARATOR . 'SureCart.php';
60 require_once __DIR__ . DIRECTORY_SEPARATOR . 'app' . DIRECTORY_SEPARATOR . 'helpers.php';
61
62 // Bootstrap plugin after all dependencies and helpers are loaded.
63 \SureCart::make()->bootstrap( require __DIR__ . DIRECTORY_SEPARATOR . 'app' . DIRECTORY_SEPARATOR . 'config.php' );
64
65 // Register hooks.
66 require_once __DIR__ . DIRECTORY_SEPARATOR . 'app' . DIRECTORY_SEPARATOR . 'hooks.php';
67