You are here

layout_builder_ids.module in Layout builder ids 8

Same filename and directory in other branches
  1. 2.0.x layout_builder_ids.module

File

layout_builder_ids.module
View source
<?php

/**
 * Implements template_preprocess_layout
 */
function layout_builder_ids_preprocess_layout(&$variables) {

  // If there is a layout builder id, set it in the attributes.
  if (isset($variables['content']['#settings']['layout_builder_id'])) {

    // Set the id attribute.
    $variables['attributes']['id'] = $variables['content']['#settings']['layout_builder_id'];
  }
}

Functions

Namesort descending Description
layout_builder_ids_preprocess_layout Implements template_preprocess_layout