Skip to content

Commit

Permalink
fix(form): bad path to css
Browse files Browse the repository at this point in the history
Signed-off-by: Thierry Bugier <[email protected]>
  • Loading branch information
btry committed Sep 21, 2020
1 parent 4819b26 commit ffff1b4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion inc/form.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -1177,7 +1177,12 @@ public function displayUserForm() {
}

// Print css media
echo Html::css(FORMCREATOR_ROOTDOC . "/css/print_form.css", ['media' => 'print']);
if (method_exists(Plugin::class, 'getWebDir')) {
$css = '/' . Plugin::getWebDir('formcreator', false) . '/css/print_form.css';
} else {
$css = '/plugins/formcreator/css/print_form.css';
}
echo Html::css($css, ['media' => 'print']);

// Display form
$formName = 'plugin_formcreator_form';
Expand Down

0 comments on commit ffff1b4

Please sign in to comment.