From 347840779f501628f4d825e7321db5112ef79e53 Mon Sep 17 00:00:00 2001 From: Oliver Tacke Date: Wed, 16 Dec 2020 16:20:52 +0100 Subject: [PATCH] Remove hardcoded directory name --- wp-h5p-xapi.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-h5p-xapi.php b/wp-h5p-xapi.php index 8f92a2d..c88a20d 100644 --- a/wp-h5p-xapi.php +++ b/wp-h5p-xapi.php @@ -19,10 +19,10 @@ function h5pxapi_enqueue_scripts() { - wp_register_script("wp-h5p-xapi", plugins_url() . "/wp-h5p-xapi/wp-h5p-xapi.js", array("jquery")); + wp_register_script("wp-h5p-xapi", plugins_url("/wp-h5p-xapi.js", __FILE__), array("jquery")); wp_enqueue_script("wp-h5p-xapi"); - wp_register_style("wp-h5p-xapi", plugins_url() . "/wp-h5p-xapi/wp-h5p-xapi.css"); + wp_register_style("wp-h5p-xapi", plugins_url("/wp-h5p-xapi.css", __FILE__)); wp_enqueue_style("wp-h5p-xapi"); $xapi_js_settings = array(); @@ -84,7 +84,7 @@ function h5pxapi_admin_init() { */ function h5pxapi_create_settings_page() { - wp_register_style("wp-h5p-xapi", plugins_url() . "/wp-h5p-xapi/wp-h5p-xapi.css"); + wp_register_style("wp-h5p-xapi", plugins_url("/wp-h5p-xapi/wp-h5p-xapi.css", __FILE__)); wp_enqueue_style("wp-h5p-xapi"); $template = new Template(__DIR__ . "/src/template/settings.tpl.php");