Skip to content
Snippets Groups Projects
Commit 1fc6fedb authored by Rajab Natshah's avatar Rajab Natshah
Browse files

Issue #3451915: Switch from Driamge to Driamge Improved in Varbase Bootstrap Paragraphs

parent 009a2975
Branches commev-alias
No related tags found
1 merge request!4Issue #3451915: Switch from Driamge to Driamge Improved in Varbase Bootstrap Paragraphs
......@@ -53,8 +53,15 @@ function varbase_bootstrap_paragraphs_preprocess_paragraph(&$variables) {
if (substr($url, -1) === '/') {
$url = substr($url, 0, -1);
}
if (\Drupal::moduleHandler()->moduleExists('drimage')) {
// Display Edge-to-Edge auto) fall back default background image using Drimage.
$file_path = $url . '/drimage/1600/0/' . $target_id . '/-' . $url . \Drupal::service('file_url_generator')->generateString($file->getFileUri());
}
elseif (\Drupal::moduleHandler()->moduleExists('drimage_improved')) {
// Display Edge-to-Edge auto) fall back default background image using Drimage.
$file_path = $url . '/drimage_improved/1600/0/' . $target_id . '/-' . $url . \Drupal::service('file_url_generator')->generateString($file->getFileUri());
}
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment