Skip to content

Instantly share code, notes, and snippets.


Katherine Senzee ksenzee

View GitHub Profile
mikecrittenden / import.php
Last active Sep 8, 2021
Importing Drupal 8 config programmatically
View import.php
// Import arbitrary config from a variable.
// Assumes $data has the data you want to import for this config.
$config = \Drupal::service('config.factory')->getEditable('filter.format.basic_html');
// Or, re-import the default config for a module or profile, etc.
\Drupal::service('config.installer')->installDefaultConfig('module', 'my_custom_module');
rauchg /
Last active Feb 19, 2021
View batch_yakety_sax.module
* Implements hook_page_alter().
function batch_yakety_sax_page_alter(&$page) {
if (current_path() == 'batch' && isset($_REQUEST['id']) && batch_load($_REQUEST['id'])) {
$page['content']['system_main']['yakety']['#markup'] = '<iframe width="100%" height="450" scrolling="no" frameborder="no" src=";color=0066cc&amp;auto_play=true&amp;hide_related=false&amp;show_artwork=true"></iframe>';