From 03e035cb98472436aff2938ca47638a228f5d86c Mon Sep 17 00:00:00 2001 From: Diego Najar Date: Sun, 27 Jan 2019 12:46:34 +0100 Subject: [PATCH] Remote content try webhook button --- bl-kernel/boot/site.php | 2 +- bl-kernel/js/variables.php | 3 +++ bl-plugins/remote-content/plugin.php | 13 +++++++++++++ 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/bl-kernel/boot/site.php b/bl-kernel/boot/site.php index e41590dc..3ecf62ba 100644 --- a/bl-kernel/boot/site.php +++ b/bl-kernel/boot/site.php @@ -25,7 +25,7 @@ if (Sanitize::pathFile(PATH_THEMES, $site->theme().DS.'init.php')) { if (Sanitize::pathFile(PATH_THEMES, $site->theme().DS.'index.php')) { include(PATH_THEMES.$site->theme().DS.'index.php'); } else { - $L->p('Please check your theme configuration'); + $L->p('Please check your theme configuration in the admin panel. Check for an active theme.'); } // Plugins after site loaded diff --git a/bl-kernel/js/variables.php b/bl-kernel/js/variables.php index 5f8cacdd..f30ab36b 100644 --- a/bl-kernel/js/variables.php +++ b/bl-kernel/js/variables.php @@ -8,6 +8,9 @@ echo 'var HTML_PATH_UPLOADS = "'.HTML_PATH_UPLOADS.'";'.PHP_EOL; echo 'var HTML_PATH_UPLOADS_THUMBNAILS = "'.HTML_PATH_UPLOADS_THUMBNAILS.'";'.PHP_EOL; echo 'var BLUDIT_VERSION = "'.BLUDIT_VERSION.'";'.PHP_EOL; echo 'var BLUDIT_BUILD = "'.BLUDIT_BUILD.'";'.PHP_EOL; +echo 'var DOMAIN = "'.DOMAIN.'";'.PHP_EOL; +echo 'var DOMAIN_BASE = "'.DOMAIN_BASE.'";'.PHP_EOL; +echo 'var DOMAIN_CONTENT = "'.DOMAIN_CONTENT.'";'.PHP_EOL; echo 'var DOMAIN_UPLOADS = "'.DOMAIN_UPLOADS.'";'.PHP_EOL; echo 'var DB_DATE_FORMAT = "'.DB_DATE_FORMAT.'";'.PHP_EOL; echo 'var AUTOSAVE_INTERVAL = "'.AUTOSAVE_INTERVAL.'";'.PHP_EOL; diff --git a/bl-plugins/remote-content/plugin.php b/bl-plugins/remote-content/plugin.php index f14b4d57..a689b90c 100644 --- a/bl-plugins/remote-content/plugin.php +++ b/bl-plugins/remote-content/plugin.php @@ -39,6 +39,19 @@ class pluginRemoteContent extends Plugin { $html .= ''.$language->get('Complete URL of the zip file').''; $html .= ''; + $html .= '
'; + $html .= '
'; + $html .= ''; +$html .= << + function tryWebhook() { + var webhook = document.getElementById("jswebhook").value; + window.open(DOMAIN_BASE+webhook, '_blank'); + } + +EOF; + $html .= '
'; + return $html; }