From d6b69630e57bc0156c7c6968b80aeb48834b37a2 Mon Sep 17 00:00:00 2001 From: Awilum Date: Wed, 21 Mar 2018 01:39:39 +0300 Subject: [PATCH] NEW BRAND NAME - FLEXTYPE --- flextype/boot/defines.php | 35 +++++++++++++++++++++++++++++++++++ flextype/boot/events.php | 16 ++++++++++++++++ flextype/boot/shortcodes.php | 18 ++++++++++++++++++ 3 files changed, 69 insertions(+) create mode 100755 flextype/boot/defines.php create mode 100644 flextype/boot/events.php create mode 100644 flextype/boot/shortcodes.php diff --git a/flextype/boot/defines.php b/flextype/boot/defines.php new file mode 100755 index 00000000..6de5b395 --- /dev/null +++ b/flextype/boot/defines.php @@ -0,0 +1,35 @@ + + * @link http://flextype.org + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +// Define the path to the root directory (without trailing slash). +define('ROOT_DIR', str_replace(DIRECTORY_SEPARATOR, '/', getcwd())); + +// Define the path to the site directory (without trailing slash). +define('SITE_PATH', ROOT_DIR . '/site'); + +// Define the path to the pages directory (without trailing slash). +define('PAGES_PATH', SITE_PATH . '/pages'); + +// Define the path to the themes directory (without trailing slash). +define('THEMES_PATH', SITE_PATH . '/themes'); + +// Define the path to the plugins directory (without trailing slash). +define('PLUGINS_PATH', SITE_PATH . '/plugins'); + +// Define the path to the config directory (without trailing slash). +define('CONFIG_PATH', SITE_PATH . '/config'); + +// Define the path to the cache directory (without trailing slash). +define('CACHE_PATH', SITE_PATH . '/cache'); + +// Define the path to the logs directory (without trailing slash). +define('LOGS_PATH', SITE_PATH . '/logs'); diff --git a/flextype/boot/events.php b/flextype/boot/events.php new file mode 100644 index 00000000..4ef04fda --- /dev/null +++ b/flextype/boot/events.php @@ -0,0 +1,16 @@ + + * @link http://flextype.org + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +// Set Flextype Meta Generator +Events::addListener('onThemeMeta', function () { + echo(''); +}); diff --git a/flextype/boot/shortcodes.php b/flextype/boot/shortcodes.php new file mode 100644 index 00000000..89bf6521 --- /dev/null +++ b/flextype/boot/shortcodes.php @@ -0,0 +1,18 @@ + + * @link http://flextype.org + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +// Add {site_url} shortcode +Shortcodes::add('site_url', function () { + return Url::getBase(); +});