The Drop Times: Inspiring Inclusion: Celebrating the Women in Drupal | #3

1 month ago
Dive into the final chapter of The DropTimes' "Women in Drupal" series, a captivating campaign launched to celebrate International Women's Day 2024. This concluding segment brings together the voices and visions of women who have shaped the Drupal community, driving forward the message of inclusion and diversity. Featured individuals like Kat Shaw, Nneka Hector, Nikita Aswani, Nina Ogor, Masami Suzuki, Tearyne D. A., Anushri Kumari, Shefali Shetty, Aastha Shrivastava, and Libbna Mathew share their experiences, challenges, and hopes for a more inclusive future.

From advocating for web accessibility to fostering diversity in tech leadership, their stories reflect a collective aspiration for change and renewal within the Drupal ecosystem and beyond. Join us in this inspiring journey as we explore the powerful narratives of these remarkable women, each contributing to the vibrant tapestry of Drupal. It's a call to inspire inclusion, celebrate achievements, and embrace the diverse voices that propel the community forward. Don't miss this insightful finale of "Women in Drupal" – let's inspire inclusion together!

Dries Buytaert: Sydney Opera House using Drupal

1 month ago

Across its 50-year history, the Sydney Opera House has welcomed musicians, dancers, actors, playwrights, filmmakers, contemporary artists, and thinkers who have both challenged and defined the cultural scene. As a result, the Sydney Opera House draws millions of visitors from around the world each year.

Not only is the Sydney Opera House of incredible cultural importance, it's also an architectural masterpiece. Its unique design makes it one of the most iconic buildings in the world, and has earned it a place as a UNESCO World Heritage Site.

Last year, the Sydney Opera House chose to migrate its website to Drupal. Today, it is running Drupal 10. The decision by such a prestigious institution to relaunch their website on Drupal highlights Drupal's flexibility, security, and ability to manage complex websites.

A couple of weeks ago, during my visit to Australia, I met with the Drupal team at the Sydney Opera House. I was particularly impressed by the team's dedication to using Open Source to expand cultural access and their enthusiasm for collaborating with other arts and cultural organizations. Their focus on innovation, inclusivity, and collaboration perfectly aligns with the core values of Open Source and the Open Web. Drupal is such a great solution for them!

Salsa Digital: Steve Worley at DrupalSouth 2024

1 month ago
Steve Worley at DrupalSouth 2024 — Day 1 Steve’s session on Day 1 at DrupalSouth 2024 looked at the benefits of a static Drupal website and different static options, including QuantCDN . From security and performance to scalability and greenness, the session explored the many big wins of static Drupal. View the presentation description on the DrupalSouth website

The Drop Times: Navigating the Currents of Change: The Multidimensional Journey of Preston So

1 month ago
Preston So, a dynamic figure in software development, showcases a rich career spanning diverse roles within the tech industry, emphasizing a leadership philosophy rooted in empathy and adaptability. Preston demonstrates a deep commitment to open-source principles and community-driven development through his extensive involvement in the Drupal community and his contributions to projects and events. His approach to tackling technical challenges and passion for sharing knowledge and fostering innovation exemplifies his impact on the Drupal ecosystem and the broader tech landscape. Explore the complete interview for further insights.

Drupal Atlanta Medium Publication: How to Configure the SMTP Module in Drupal 10 with Gmail, Since Google Removed Less Secure Apps

1 month ago
Starting on September 30, 2024, Google no longer allows you to enable the less secure apps. Learn how to add app-specific passwords for your Google Account.Sending Drupal 10 website Emails through Googles SMTP

To ensure your Drupal 10 website can send emails, like password reset links, you must configure the SMTP Module, especially after Google’s policy change on September 30, 2024, which prohibits the use of less secure apps. This guide will show you how to set up the SMTP Module in Drupal 10 for sending password reset emails and other form submissions via Gmail.

Before you begin, ensure you have the necessary tools. You will need Composer and Drush installed on your computer. Additionally, you must have access to a Gmail account and its password, which will be used to send the emails. Follow these steps to configure SMTP in Drupal 10, ensuring your site’s email functionality is uninterrupted by Google’s security updates.

Note: The instructions below are for a standard Gmail and have not been tested on a Google Workspace email address.

Download and Enable the Module
  • First, you must download and enable the module.
    - We are going to use composer to download and then a drush command to enable it. Or you could just enable the module in the
composer require 'drupal/smtp'

drush en smtp -yConfigure the SMTP Module in Drupal
  • Navigate to the configuration page admin/config/system/smtp
  • Under Turn this module on or off select On.
  • Under SMTP server enter the following smtp.gmail.com. Leave SMTP backup server blank
  • Under SMTP port enter 587
  • Under Use encrypted protocol select Use TLS
  • Under E-MAIL OPTIONS use the same Gmail address as you did above and enter an E-mail from name
Update Gmail Account SettingsCreate App-Specific Password for GMAIL

How to Configure the SMTP Module in Drupal 10 with Gmail, Since Google Removed Less Secure Apps was originally published in Drupal Atlanta on Medium, where people are continuing the conversation by highlighting and responding to this story.

ComputerMinds.co.uk: Format Drush output for easy wins!

1 month ago

Drush, the brilliant command-line tool for Drupal, is capable of giving you its output in several ways. Its global --format parameter can be set to a type that you can use in useful ways. Most recently, I found this incredibly useful when I had made some configuration changes through Drupal's admin pages, and needed to then script those changes to automatically apply to hundreds of sites on a platform we manage.

I simply asked Drush for the value of the configuration I had set, formatted as the PHP code to set those values. Then I could drop that into our PHP automatic update script. Here are two examples - one getting just a single property of a block placement, and another for the whole settings object for a module.

# Get the visibility conditions of my block. drush config:get block.block.myblock visibility --format=var_export # Get the whole settings singleton for my module. drush config:get mymodule.settings --format=var_export

The var_export format provides the output using PHP's traditional array syntax, instead of the default YAML (which matches the format of config export files). Here's an example of the output for another type of configuration, an action:

array ( 'uuid' => 'faaaea7f-d377-4b9c-bbfb-bd1b9c562050', 'langcode' => 'en', 'status' => true, 'dependencies' => array ( 'module' => array ( 0 => 'mymodule', ), ), '_core' => array ( 'default_config_hash' => 'vvt7bzrXEwxrTfY--axzCfSRPzggH0o4hahUY9Kh0z0', ), 'id' => 'mymodule_foo_action', 'label' => 'An example action', 'type' => 'webform', 'plugin' => 'mymodule_foo_action', 'configuration' => array ( ), )

Then I could just copy the output and paste it into a post-update hook. My IDE makes it easier to prettify the code to match Drupal's coding standards and switch to PHP's newer short array syntax. I also removed all the bits that I could leave to be dynamic; like the uuid, _core, and empty configuration properties in the action example above. I can then either use the entity storage for my type of entity to save the configuration, or just use the Configuration Factory service more directly:

$data = // (Paste & adapt the output from drush for this variable.) // Example of using the config factory. $config = \Drupal::configFactory()->getEditable('block.block.myblock'); // Using `setData()` will replace the entire config array. We could instead // use `set()` for individual properties. $config->setData($data)->save(); // Alternatively use the entity type storage and specific methods, when // available. Create new entities with `$storage->create($settings)->save()`. $storage = \Drupal::entityTypeManager()->getStorage('block'); $storage->load('myblock')->set('settings', $data['settings'])->save();

We tend to automate Drupal core's configuration management on most of our projects - but not always. Even where we don't, there is usually some config that we exclude from the automated management - usually to allow clients to make changes in the admin UI without needing to access the codebase. So this is a handy trick to have available when you just need to script some changes outside of config management.

Under the hood, the consolidation/output-formatters library is what provides output formatters. If you run drush help version you can get a list of other standard formatters, which includes:

yaml

The key-value format usually used for configuration exports.

csv

Comma-separated values; ideal for simple lists

php

The format that PHP's internal serialize() method produces.

var_dump

Probably my new favourite; as produces coloured syntax highlighting in the terminal output! It is powered by Symfony's VarDumper component. I have found this particularly useful recently when debugging the output from a remote API endpoint, to help me visually parse clumps of output.

As a bonus, this can be useful for quickly loading up an entity to inspect its field values:

getStorage('taxonomy_term')->load(11)->toArray());" --format=var_dump`" data-entity-type="file" data-entity-uuid="9930f0b8-e138-4ae8-8432-1e42a2e7086b" src="https://www.computerminds.co.uk/sites/default/files/inline-images/drush-var-dumping.png" width="692" height="834" loading="lazy" /> My output from drush php-eval "return array_filter(\\Drupal::entityTypeManager()->getStorage('subscriber')->load(127)->toArray());" --format=var_dump

...which feels rather like a good case for a custom drush command, just taking an entity type and ID as arguments ;-)

What other handy uses of specifying an output format can you come up with? Let me know!

Tag1 Consulting: Drupal Core Test Suite Improved Runtime By 10% With Gander

1 month ago

The Drupal community has continuously sought ways to enhance the performance and efficiency of Drupal sites. The performance testing framework Gander has been part of Drupal core since version 10.2. The result of joint efforts between the Google Chrome team and Tag1 Consulting, this powerful tool is specifically designed to optimize Drupal performance. Optimized performance ensures that sites are not only fast but also efficient and sustainable. Today, we will take a closer look at how Gander played a crucial role in improving the Drupal core test suite runtime by 10%. ## Identifying A Core Performance Issue Gander's impact on Drupal development was recently highlighted by its identification of a performance issue within Drupal core. The issue (#3410312) reported a particular code section being called redundantly during automated test runs and on live websites, resulting in delays. ### The Bottleneck Identified Drupal is designed to use the flood system for user logins. It first checks if a flood protection table exists in the database. If it does not exist, Drupal postpones the creation of the table until it needs to write to it instead of creating the missing table immediately. What can happen is...

Read more janez Wed, 04/03/2024 - 02:00
Checked
11 hours 22 minutes ago
Drupal.org - aggregated feeds in category Planet Drupal
Subscribe to Drupal Planet feed