Jul 17 2019
Jul 17

The Drupal community maintains its own set of evergreen coding standards that differs from those of the broader PHP community (e.g., PSR-2). It's encouraged to pour through the standards line-by-line and memorize each for perfect real-time compliance, but for those with better things to do, fear not! The standards will come to you. When starting new projects, just add a composer dependency on vijaycs85/drupal-quality-checker. This tool uses GrumPHP to add a pre-commit hook that checks new code for violations of the Drupal coding standards and outputs helpful information to aid the developer in resolving each one.

What is GrumPHP?

GrumPHP is a clever tool that automatically adds git pre-commit and commit-msg hooks to your local environment to check coding standards before committing. Since git hooks depend on your local git repository configuration and are not part of the codebase, GrumPHP uses Composer to modify the .git/hooks/pre-commit file on your disk.

Let’s review some of the “gotchas” you might run into.

Grrr, I can’t commit my WIP code because it violates Drupal coding standards!

When warranted, use the --no-verify (-n) flag to skip the checks.

git commit -n

But don’t forget to go back and fix them later! Use the --amend flag to “re-do” the commit (before pushing) to trigger GrumPHP to check for errors.

git commit --amend

I can't commit commented-out code, seriously?

Generally speaking, don't commit commented-out code. Instead, rely on the powerful mechanisms provided by git for pulling lines from the VCS history. "What about new code that I have yet to commit but want to keep around for later?" Well, go ahead and commit it (with --no-verify, to skip the checks), then revert the commit (git revert). And voila, now it's available to you in the VCS history.

Sometimes, though, this is just not practical or desirable, and there remain legitimate cases for committing commented-out code. What are your options?

  1. Use @code ... @endcode tags in docblock comments. When adding code samples to functions, files, or class docblocks, using the @code ... @endcode tags prevent PHPCS from throwing a warning.
  2. Prevent coding standards checks on specific lines, code blocks, or entire files. See the next section for details.

But really, deeply, truly, the standards are wrong here, I swear!

If you disagree with or don’t want to follow the standards for whatever reason, here’s how you can whitelist specific lines and files.

Whitelist a single line:

<?php
// @codingStandardsIgnoreLine
$honeyBadger = new HoneyBadger();


<?php
$honeyBadger = new HoneyBadger(); // @codingStandardsIgnoreLine

Whitelist a code block:

<?php
// @codingStandardsIgnoreStart
$honeyBadger = new HoneyBadger();
if ($honeyBadger.cares()) throw new Exception();
// @codingStandardsIgnoreEnd

Whitelist an entire file:

<?php
// @codingStandardsIgnoreFile
class HoneyBadger {
  public function cares() { return FALSE; }
}

OMG, so many errors

If you write a lot of code/make many changes before committing, you may end up with a miles-long list of violations to fix—a real pain when you thought you were done and ready to push! So rather than depending on this git pre-commit check, make your life easier by taking care of the issues as you go. And no, you don’t need to memorize all the Drupal coding standards by heart; there are plugins for every major code editor to help you out. They provide real-time, inline feedback as soon as you write code that doesn’t pass muster; much easier than bouncing back and forth between the error list in your git client and the code, hunting for files and line numbers. Furthermore, your editor can generate the full list of violations and link you straight to the offending lines.

To get started, follow the steps in this Drupal.org documentation page: Installing Coder Sniffer. When the documentation talks about installing PHPCS and the Drupal standards globally, you can instead point it to your project-local version, if you wish:

  • PHP_CodeSniffer command: /path/to/repo/vendor/bin/phpcs
  • Drupal coding standard “sniffs”: /path/to/repo/vendor/drupal/coder/coder_sniffer/Drupal

GrumPHP doesn't do anything?

If GrumPHP shows all green checkmarks when you know there are violations, you may have an issue with the configuration, or your project may not be compatible with GrumPHP. For example, certain project structure hierarchies are not yet supported. Good luck with that! Just kidding, here’s some help.

Furthermore, note that the GrumPHP pre-commit script only checks your added/changed files for violations, not all the code in your project. Generally, this is a good thing, as you don’t want to fix unrelated code in your pull request. But if you do want to run a complete check of all the code in the repository or a specific directory, you can use your code editor to generate a report or one of these command-line tools:

php path/to/repo/vendor/bin/grumphp run

If you need to customize the list of files to include or ignore:

path/to/repo/vendor/bin/phpcs \
  --standard=Drupal           \
  --ignore=*.css              \
  web/modules/custom          \
  web/themes

Extra Credit

The tools described so far help with accidentally committing code that violates Drupal standards, but it doesn’t prevent it entirely. To do that, you’ll want to add a test to your Continuous Integration (CI) workflow that flags pull requests with code that violates a standard.

CI tooling is outside the scope of this post, but lots of good resources exist. Check out this excellent blog post to help you get started: Continuous Integration for Drupal 8 with CircleCI.

Conclusion

Are you ready to get started? It’s as simple as running this command:

composer require vijaycs85/drupal-quality-checker

There’s also a newer kid on the block: drupol/drupal-conventions. I can’t vouch for it as I’ve not yet tried it on a project, but it looks promising and includes a “fixer” config to automatically fix small/unambiguous issues for you.

composer require drupol/drupal-conventions

I hope this has been a helpful post to all. If you have suggestions, improvements, or corrections, please comment below or @ me on drupal.org, thanks!

Jul 17 2019
Jul 17
Project: Drupal coreDate: 2019-July-17Security risk: Critical 17∕25 AC:None/A:None/CI:Some/II:Some/E:Theoretical/TD:DefaultVulnerability: Access bypassCVE IDs: CVE-2019-6342Description: 

In Drupal 8.7.4, when the experimental Workspaces module is enabled, an access bypass condition is created.

This can be mitigated by disabling the Workspaces module. It does not affect any release other than Drupal 8.7.4.

Drupal 8.7.3 and earlier, Drupal 8.6.x and earlier, and Drupal 7.x are not affected.

Solution: 

If the site is running Drupal 8.7.4, upgrade to Drupal 8.7.5.

Note, manual step needed. For sites with the Workspaces module enabled, update.php needs to run to ensure a required cache clear. If there is a reverse proxy cache or content delivery network (e.g. Varnish, CloudFlare) it is also advisable to clear these as well.

Reported By: Fixed By: 
Jul 17 2019
Jul 17

What is the latest business forecast for the media and publishing industry? The thunder and lightning of success! This is because Drupal has very useful web solutions for this industry.

In addition to easy content editing in Drupal 8 and other niceties, there are Drupal distributions for media and publishing. They are called Thunder and Lightning, and we will now discuss what they can give you.

What are Drupal distributions?

Distributions are meant to start a website with significant time and cost savings. This is because Drupal distributions are installation kits suited to specific business use cases.

These packages include the Drupal core, a set of contributed modules, specific configuration, and more. Distributions are free and ready to go. They can be customized and extended by development teams to meet your business needs.

Drupal distributions for media and publishing

Thunder and Lightning are very famous Drupal distributions for media and publishing. They sound like a pair of related projects, but they are actually from different creators. Let’s review the details of each of them.

Lightning — Drupal distribution for media and publishing

Lightning is a framework and a distribution in one. It empowers developers to build great authoring experiences. And it allows content editors and publishers to enjoy smooth, handy, and consistent workflows.

The Lightning distribution was developed by Acquia in 2016. It is a lightweight and extensible product provided with detailed documentation and recommendations. Lightning inherits the best Drupal practices and offers a set of modules without being overloaded by extraneous ones.

about lightning drupal distribution

The distribution’s reliability is guaranteed by 60+ automated tests and by Drupal Security Team’s close attention. This makes it much safer to use than a selection of standalone modules.

The project is actively maintained and has seen its 8.x-4.001 version released in June 2019. Lightning is the most downloadable Drupal 8 distribution on drupal.org in general, not only among Drupal 8 distributions for media and publishing.

Distributions Drupal.org Lightning

Key Lightning features for publishers

  • Easy media management

Lightning includes the media management feature with the media library. Content publishers can upload images and videos from a PC or from a URL, save them to the library, or embed them into the content.

  • Flexible editorial workflows

With Lightning, it is easy to streamline content workflows between different user roles in the team. Publishers can manage the existing ones, or create new content approval states.

  • Handy content preview

Editors can enjoy a comprehensive content preview, including images and videos, before submitting it to the public.

  • Drag-and-drop layouts

The handy drag-and-drop tools allow editors to shape their page layouts for different occasions. The layouts are responsive to mobile devices. 

  • API for content sharing

 Lightning has a preconfigured API for exposing content to other applications in the JSON format, so your media website can go multichannel.

  • Headless Lightning subprofile

The subprofile has the same features but also offers an interface for decoupled Drupal setup, which is a hot trend. According to Dane Powell, Senior Technical Architect at Acquia, both Lightning and Headless Lightning are a great choice for this architecture.

key features of lightning drupal distribution

Thunder — Drupal distribution for media and publishing

The Thunder distribution is an out-of-the-box product to be used by professional media websites. On its official page, Thunder positions itself as a CMS (content management system) for professional publishing.

It includes a set of specific modules tailored to the needs of publishers. Similarly to Lightning, Thunder is free and open-source.

about thunder drupal distribution

Thunder was created in 2016 by Hubert Burda Media. In addition to the Thunder Core Team, the project is maintained by partners from the Thunder Coalition such as Nexxt.tv, Acquia, Valiton, Facebook etc. that add their own custom features to it. The distribution’s creation was great news for the Drupal world.

about thunder drupal distribution

And just like Lightning, Thunder is actively supported and has released it 8.x-2.4 version in June 2019.

Key Thunder features for publishers

  • Flexible content creation

Publishers can create more than simple articles by adding elements like images, videos, galleries, Twitter cards, and more with a drag-and-drop tool. Media can be saved for further reuse.

  • Content scheduling

Your content can be scheduled to show on the website at a given date and time or, on the contrary, to stop showing at a given time.

  • Nexx.tv video player

Thunder features a high-performance Nexx.tv video player that allows publishers to control their videos across platforms and devices.

  • Riddle tool for interactive content

There is a Riddle that allows you to create interactive content like quizzes, tests, and so on. This keeps users engaged and drives your traffic.

  • Instant Articles by Facebook

With the Instant Articles feature by Facebook, publishers can create articles that will load instantly on mobile devices of Facebook app users. 

  • The Infinity theme

This is a special theme created for media and publishing websites by InStyle. It allows website to present content and increase user engagement with infinite scrolling.

  • Mobile-friendliness

The distribution allows publishers to work in the admin dashboard from any device. Users can enjoy a modern and flexible front-end design.

key features of thunder drupal distribution

Get the best from Drupal distributions for media and publishing

These have been just a very brief rundown of the Lightning and Thunder capabilities. They both are built according to the best development practices and both can be a great base for your website.

Contact our Drupal development team and we will help you quickly setup a website upon one of these distributions. Let your media and publishing business flourish with a website that reflects its demands!

Jul 17 2019
Jul 17

The Migrate Drupal UI module provides a web browser user interface for upgrading from Drupal 6 / 7 to Drupal 8. There is a pre-upgrade analysis which displays a list of legacy modules that will be upgraded and will not be upgraded. Included in those that will be upgraded are modules that do not need an upgrade, such as the Help module. In order for this analysis to be correct, some Drupal 8 modules must provide information in a MODULE_NAME.migrate_drupal.yml file in the module's migrations/state directory.

This applies to Drupal 8 modules that:

  • Provide migrations from a Drupal 6 or Drupal 7 module, or
  • Intend to provide those migrations in the future, or
  • Are a successor to a Drupal 6 or Drupal 7 module and want to communicate that no migration is needed.

This does not apply to modules that are brand new in Drupal 8 and have nothing to communicate about any Drupal 6 or Drupal 7 modules.

Syntax

finished:
  6:
    source_module: destination_module
    source_module_2: destination_module
    source_module_3:
    - destination_module
    - destination_module_2

  7:
    source_module: destination_module
    source_module_3:
    - destination_module
    - destination_module_2

not_finished:
  7:
    source_module_2: destination_module

As can be seen above, the data in migrations/state/MODULE_NAME.migrate_drupal.yml consists of migration sets where each set is a source module for a legacy Drupal version (6 or 7), and one or more destination modules for the current Drupal version (8). The source module and destination modules correspond to the source_module and destination_module definitions in the migrations. And each set can be declared either 'finished' or 'not_finished'. For a set to be "finished", all of the migrations for the set must exist. If a module maintainer knows that they have not yet provided all of the migrations that are needed from a given source module to one or more destination modules, then they should declare that set as "not_finished".

Merging state across provider modules, source modules, and destination modules

Each module's migrations/state/MODULE_NAME.migrate_drupal.yml file defines the state of the migrations that are provided (or intended to be provided in the future) by that module. In most cases, destination modules are the sole providers of migrations to themselves. For example, the dblog module is the sole module that provides migrations from earlier versions of itself to itself. In some cases, modules provide migrations for other destination modules. For example, the Content Translation module provides migrations from earlier versions of the Statistics module to the current version of the Statistics module. This is in addition to the migrations provided by the Statistics module itself.

The Migrate Drupal module considers a source module / destination module pair as not finished if there is any provider that declares it as not finished. For example, in the above example, if the Content Translation module in its .migrate_drupal.yml were to declare that statistics: statistics were "not_finished", then Migrate Drupal considers that pair to be not finished, even if the Statistics module itself is finished with the migrations that it intends to provide.

Similarly, a given source module is considered not finished overall, if there exists at least one destination module for which it is declared as not finished. For example, there are migrations from the Drupal 6/7 Menu module to several Drupal 8 destination modules (System, Menu UI, and Custom Menu Links). If any one of those pairs (e.g., menu: system, menu: menu_ui, or menu: menu_link_content) were declared as not finished (by any provider module), then on the Migrate Drupal UI pre-upgrade review screen, the Menu module would be listed as "will not be upgraded".

Usage

If the Drupal 8 module is not providing migrations, now or in the future, for its legacy version then create a migrate_drupal.yml. Declare a finished migration for each legacy Drupal version. See scenario 1 below.

If the Drupal 8 module is or will be providing migrations for a legacy module then create a migrate_drupal.yml file. For each source_module:destination_module pair used by the migrations in your module do the following for Drupal 6 and Drupal 7.

  • If the migrations for the pair are complete add a line in the "finished" array for the relevant Drupal version.
  • If at least one migration for a pair exists but the pair is not finished add an entry to "not_finished" for the relevant Drupal version.
  • If the migrations needed for the pair do not exist then add a line in the "not_finished" array for the relevant Drupal versions.

Examples

Scenario 1. A successor to a legacy module that for any reason will not be providing a migration. Let's use Pirate as the example. Currently, if Pirate is enabled on the legacy site it will be displayed as will not be upgraded when it should be listed as will be upgraded. To make that happen simply declare a migration set with pirate as the source module and destination module as finished.

finished:
  6:
     pirate: pirate
  7:
     pirate: pirate

Scenario 2. The legacy version of your module has content and configuration that needs to be upgraded. Your module provides two migrations with the same source_module:destination_module pair for both Drupal 6 and Drupal 7 and all migrations are finished.

finished:
   6:
     google_analytics: google_analytics
   7:
     google_analytics: google_analytics

Scenario 3. Your module provides migrations. The Drupal 6 version is complete but the Drupal 7 is not. Note there may be zero or more migrations for Drupal 7 in your module but more are needed for it to be complete.

 finished:
    6:
      google_analytics: google_analytics
  not_finished:
    7:
      google_analytics: google_analytics

Scenario 4. Your module provides migrations for other modules with many pairs, such as Commerce Migrate Module.

finished:
    6:
      node: commerce_product
      system: commerce_store
    7:
      node: commerce_product
      commerce_product: commerce_product
      system: commerce_store
  not_finished:
    6:
      uc_orders: commerce_order
    7:
      uc_orders: commerce_order
      commerce_order: commerce_order

Scenario 5. Your module provides a migrate field plugin for a legacy field, such as Address Module.

  finished:
    6:
      adressfield: address
    7:
      adressfield: address

Scenario 6. Menu, JQuery UI, Blog, Color and many other modules moved directly into Core. These are denoted as 'core' for the destination and are treated specially. They are marked as finished since these do not have an upgrade path and site upgraders do not need to look for an equivalent project to install in Drupal 8.

finished:
  6:
    blog: core
    blogapi: core
    calendarsignup: core
    color: color
  7:
    blog: core
    bulk_export: core
    contextual: core
    ctools: core

Cheers :)

Jul 17 2019
Jul 17

by on Jul 17, 2019 in Drupal, Web Development

Packed with multiple powerful features, including greater flexibility, higher page load speed, and scalability, Drupal 8 was launched more than two years ago. If you haven’t upgraded to Drupal 8, you should consider doing it now!

In our blog post, we talk about how Drupal 8 is beneficial for your business. Let’s dive in.

”Benefits

Mobile Friendly

Drupal 8 is built keeping mobile in mind. It keeps up with the times by being fully responsive and mobile-friendly. Drupal puts mobile users at its core and uses the mobile-first approach. It handles content loading quickly which means your audience would not waste their time.

In other words, upgrading to Drupal 8 gives you a mobile-friendly website that is easy to administer from all the devices.

Content Authoring

Drupal is not just mobile-friendly for end-users but it also allows content editors to administer their website from mobile devices. The new interface allows content creation, publishing, and editing of the content on the front-end. This means your users will always have the best possible experience on your website.

Multilingual Capabilities

Translation has never been this easy. The Drupal 8 translation system is newly written and is fully integrated into the CMS that makes installation in different languages easier. Businesses with a target global audience can take advantage of Drupal’s multilingual capabilities.

The recent version is configured with a powerful translation module with content translation, configuration translation, and interface translation. It enables you to translate any component of the software, image styles, comments. You can also get software translation updates from the community hence saving a lot of time and money.

Higher Security Level

Drupal has a strong and robust security system in place. It has an organized process for verifying, investigating, and publishing possible security problems.

Drupal’s security team regularly works with the community to address security issues as they arise.

For businesses using Drupal 8, it is important that they subscribe to the security mailing list and stay updated with the recent security advisors of all types.

Flexible integration with Marketing Tools

Drupal 8, is an important part of your marketing ecosystem – with commerce-first and community-first marketing solutions to achieve the most ambitious business goals.

When it comes to third-party integrations, Drupal 8 is the most flexible CMS. Along with the APIs, Drupal will permit any business to quickly integrate the recent technologies, delivering exclusive customer experience.

SEO Friendly

Known as SEO-friendly CMS, Drupal 8 has become even more advanced by improving search engine optimization results. Drupal 8 uses industry-leading caching technology to permit access to the updated content. It helps preserve the content that has not changed. So, after your visitors come to your website, they would not have to wait for all the content to load each time.

RESTful Web Services

When you use Drupal 8, web services work out-of-the-box here. There is no need to download any additional modules as all the important tools are already included in the core with the required modules.

Drupal 8 makes the integration with marketing automation platforms easier and fetch data faster as compared to other APIs. This is the reason why REST web services have evolved quickly.

Key Takeaway

The latest Drupal version is open-source, which is easy to access and operate. It has added a number of enhancements, themes, and free plugins that make the system even more flexible, scalable, and user-friendly.

Want more information about Drupal Services?

At Grazitti Interactive, we offer best-in-class website development services using latest CMS’s like Drupal, WordPress, Joomla, and more with advanced technologies such as PHP, ASP.net, AJAX, JavaScript, jQuery’, AngularJS, etc., To know more, send us an email at [email protected]

Tags:

DrupalWeb development

Related Articles

Jul 17 2019
Jul 17

The Apigee Dev Portal does not support SOAP/WSDL (Simple Object Access Protocol/Web Service Definition Language) documentation by design. However, Apigee is seeing a number of prospects and customers who have legacy SOAP APIs that they want to onboard onto Apigee Edge quickly.  Apigee’s current strategy is to put a REST (Representational State Transfer) facade in front of a SOAP backend as an interim solution. This way customers can take advantage of the out-of-the-box analytics as part of their rationalization exercise to improve and build new RESTful APIs. However, these enterprise clients want to display WSDL documentation in addition to RESTful API documentation.  As including comprehensive SOAP/WSDL documentation in the Apigee Dev Portal is not the end goal, this module (Drupal’s equivalent of an “app” or “plugin”)  was imagined as an interim solution. It can act as a stand-alone module to be used to quickly get a client ramped up on the Apigee platform without having to do the impossible task of ripping out and rewriting their entire SOAP API “overnight.”  

Background

Development of this module serves as an example of how something can be built quickly by borrowing from other of Drupal contributed modules.  The codebase we used first started as a standalone form to easily send requests to web services as the sandbox project Webservices Client Tester. It then became absorbed into the Drupal project Web Service Client.  Later on, it was customized to focus on testing only SOAP web services. This latest iteration is what we built upon, however, it was not fully baked, loaded with commented code and had some key functionality (sending SOAP requests) that was broken.  After significant refactoring, things looked good enough to start building out our requirements.


A WSDL file for SOAP is similar to an OpenAPI spec for REST. It describes a web service/API  to developers who want to work with it.  The original sandbox Web Services Client Tester module provides an admin UI to import a WSDL. It then stores it as a JSON object inside two tables, operations and parameters.  In the Drupal admin, you can view the methods and parameters and view traced SOAP requests. This did not fit our use case as we wanted to create documentation for a developer, not simply create a Drupal admin page for testing.  

The best application we could find to convert WSDL files to human readable documentation was WSDL viewer, so this was used as a guide.  Our solution was to follow the model of the Apigee Dev Portal SmartDocs by generating nodes for each operation and then rendering the SOAP trace form on each node.  By choosing to display each operation on a node, it allows SEO friendly navigation of documentation throughout the Dev Portal and the flexibility to display the operation nodes in views.

Importing the WSDL and generating nodes.


In addition to importing through the UI we needed to create a REST endpoint to import the WSDL for continuous integration (CI/CD), the endpoint is created with hook_menu()and runs the import function that generates the nodes and parses the data. This function can also be called from the Drupal admin by submitting the URL of the WSDL through a form.

For imports via file upload we post.

content-type: application/octet-stream 

For imports via URL parameter. 

content-type: application/x-www-form-urlencoded.  

We pass the name parameter In the URL to define a label for the web service as this is defined manually when imported via the Drupal admin UI. 

 /smartdocs_wsdl_import?name=mytestservice

If we are importing by URL we also pass a “url” parameter with the location of the WSDL.  If we find no $_POST data for URL, we recognize the WSDL as a file upload, we then use file_get_contents('php://input') to save it to the server and create the service record in the DB.

/smartdocs_wsdl_import?name=mytestservice?nameurl=http://company-eval-test.apigee.net/simplesoap/SOAP_server/ndfdXMLserver... 

We check if the WSDL filename exists in our table.  If it does not exist we create the service. If it does exist we update the existing service with a new timestamp and user information and then update all existing operation node/ 

Finally, if we delete the service ID from the Drupal admin all corresponding operation nodes related by ID are deleted.

We added basic auth functionality to the endpoint by copying some code from Basic HTTP Authentication module to the access callback on the menu item. This leverages Drupal’s flood_register_event for extra security, by logging failed attempts to the ‘flood table’/  Admins can view the IP address and timestamp of any failed POST to our endpoint, and a user can also add the Flood Control module to easily view these via the admin UI.


Parsing Elements


Parsing the WSDL file into Drupal fields had its own set of challenges.   


The output of the operation is very important for the developer to know so they clearly see what kind of data they can expect as a return value to their API calls.  Parsing the data from the operations was a challenge however because they are not simply stored in an <output> element inside the <operation> element. That’s just not how WSDL files work.

Say we want to parse the output for the operation LatLonListZipCode and store it on a field.  We start with the <operation> element where we find GetFlightData, 


<wsdl:operation name="GetFlightData">
<wsdl:documentation>Returns basic flight information.</wsdl:documentation>
<wsdl:input message="tns:GetFlightDataHttpPostIn" />
<wsdl:output message="tns:GetFlightDataHttpPostOut" />
</wsdl:operation>


We then follow that to the <message> element GetFlightDataHttpPostOut where we need to parse the name and type values.
 
<wsdl:message name="GetFlightDataHttpPostIn">
<wsdl:part name="Userid" type="s:string" />
<wsdl:part name="Password" type="s:string" />
<wsdl:part name="ACID" type="s:string" />
</wsdl:message>

In order to display the data as nested, we have a custom function that loops through the parsed data returning the text inside <li> tags. We then set the form field config to “text area” with input format “full HTML” in Drupal admin.

It’s this kind of unintuitive structure of the WSDL that makes the move to REST and JSON look so very reasonable. This module is a tool in Apigee’s vision towards promoting the move towards a RESTful web, by serving as a stepping stone for companies with SOAP based APIs. 

I was fortunate to work with two other great developers Karl and Deb from Achieve who provided me with excellent feedback throughout development. I find the process of being able to demo and show work to a supportive team throughout development as one of the keys to the successful delivery of quality code on time.
 

Jul 16 2019
Jul 16

Shape the exciting lineup of community-driven, educational sessions by serving on the Program Committee!

Jul 16 2019
Jul 16

Our normally scheduled call to chat about all things Drupal and nonprofits will happen this Thursday, July 18, at 1pm ET / 10am PT. (Convert to your local time zone.)

Feel free to share your thoughts and discussion points ahead of time in our collaborative Google doc: https://nten.org/drupal/notes

Already on the agenda: A discussion of announced changes to 20NTC, which specifically impact the community driven sessions our great group of volunteers organized last year.

We have an hour to chat so bring your best Drupal topics and let's do this thing!

Some examples to get your mind firing: how do I recreate [feature] on my Drupal 7 site in Drupal 8? I need to explain [complicated thing] to a non-technical stakeholder -- any advice? How can I get Drupal and my CRM to play nicely?

This free call is sponsored by NTEN.org but open to everyone.

View notes of previous months' calls.

Jul 16 2019
Jul 16

The Embedded Google Docs Field allows the site administrator to change the display of normal file fields, making them viewable directly on the node with the help of the Google Docs Viewer.

This tutorial will explain the usage of this module through an example.

Let’s start!

Hint: Google has to be able to locate your site on the web, in order to embed the viewer. This module will not work in a local environment.

Step # 1. Install the required modules

  • Open the terminal application on your computer
  • Place the cursor on the root of your Drupal installation (the composer.json file is located there)
  • Type:

composer require drupal/gdoc_field

Add the composer command

  • Click Extend
  • Scroll down until you find the module and enable it
  • Click Install

Click Install

Step #2. Add a File Field

  • Click Structure > Content types
  • Click Manage fields in order to create a new file field in the Basic Page content type

Create a new file field in the Basic Page

  • Click Add field
  • Select a field from type File and give it a proper label
  • Click Save and continue

Click Save and continue

  • Click Save field settings in order to leave the default values

Click Save field settings

  • Add the proper help text to be shown to the editor when creating the node
  • Mark this field as required
  • Add some more file extensions (only text documents would be boring)
  • Click Save settings

Click Save settings

  • Open the dropdown options for the Basic Page content type and select Manage display

Select Manage display

  • Hide the file field label
  • Select the Embedded Google Documents Viewer as formatter
  • Click Save

Click Save

Step #3. Create the Content

  • Click Content > Add content > Basic Page
  • Write a proper title and body text
  • Click the Select button in order to upload a document

Click Select button

You will see the link to the document once it has been uploaded.

  • Click Save

Click Save

Take a look at the node, the document should be displayed in an iframe right after the body text.

Take a look at the node

Step #4. Theming the Viewer

To add styles to the embedded iframe, it is necessary to target the gdoc-field class. Furthermore, you can customize the viewer even more by using template overrides. The default template is called gdoc-field.html.twig.

The default template is called gdoc-field.html.twig

I really hope that your design taste is much better than mine.

I also hope this tutorial will help you broaden your site-builder skills by adding this simple but useful module to your personal knowledge base. Please, leave us your comments and suggestions below.

Thanks for reading!


About the author

Jorge lived in Ecuador and Germany. Now he is back to his homeland Colombia. He spends his time translating from English and German to Spanish. He enjoys playing with Drupal and other Open Source Content Management Systems and technologies.
Jul 16 2019
Jul 16

Great vision without great people is irrelevant - James Collins 

As Collins describes in his book - "Good to Great,” we often expect the good-to-great leaders to begin their quest for greatness by setting a new vision and strategy. Instead, they first get the right people on the bus, the wrong people off the bus, and the right people in the right seats. Then, they figure out where to drive it! 

Hiring a professional team of experts is a common challenge faced by most companies in today's world. And the process of hiring gets tougher when you want to hire a team of talented individuals in the open-source industry, particularly in the Drupal community.  

While there are a plethora of Drupal agencies with developers - all working with, in, for Drupal, the real challenge is narrowing down to find the right partner to suit the needs of your organization, long or short term.

With fierce competition and the never-ending challenges, how do you hire a Drupal developer or a team of experts who is the right fit for the project?

Be sure of what you need

Need someone with expertise in building multisite websites with multiple Drupal codebase & custom theming? Say it! Or, if you need someone with experience in creating custom modules and specializes in building Enterprise websites? Say So! 

Since different drupal project types demand different talents, it is very important that you understand the key process involved in the project development when you hire a drupal developer

Before you reach out to a Drupal agency, it is essential that you know the scope of the project for which you need the Drupal developers for. This will lead you to the most important elements to be considered before the start of the project. The limitations of the budget and the timeline. 

The nearly impossible task of getting quality work done by meticulously following the timeline set before the start of the project is something that should always be in the back of your mind. Add to it the budget constraints, and the bracket narrows further down. 

However, most Drupal companies offer a productive staff augmentation services that will allow them to scale in tandem with your business needs and these constraints can be handled by the right Drupal partner. 

Know Your Drupal Partner

From the front-end & back-end Drupal developers to the DevOps personnel and the QA testers, it is very important that the Drupal agency has the right team. 

Your project will have various tasks that will require more than one skill set, and if your Drupal partner and its team of experts can't handle the requirements, it will pose a serious threat to the development efforts. 

Thus, it is better to consider the experience levels of the team you want to hire, how long have they worked on Drupal and how familiar are they with the previous versions of the CMS. An experienced team of Drupal experts will know what goes where and their skill set will always play a vital role in crunch situations.   
 

A part of the Drupal Community?

As an open source platform, Drupal does a phenomenal job in encouraging its individual members and teams to actively contribute to the betterment of the platform. Thousands of developers strive to improve Drupal and it is important to see how big of a role is the Drupal agency you pick, is playing an active role in encouraging its developers to be a part of the community. 

Acquia Certified - An added advantage
 

Started in early 2014, Acquia has a certification program for Drupal developers looking to improve their proficiency in the particular field. An Acquia Certified resource stands apart from the plethora of drupal professionals out there. Having a certified member in the team will act as an added advantage as his proficiency and expertise will play an essential role in the  amelioration of the project development workflow. 

Support & Maintenance? 

While Drupal offers constant updates for security & other vulnerabilities, it is important that your Drupal partner is accessible when you need these upgrades the most. You do not want to end up being stranded when you face glitches in an already deployed project. Most agencies offer Drupal support & maintenance services to ensure a smooth, secure and a seamless performance of your website. 

Not Just Drupal

Web application development with Drupal may also require your Drupal expert to be proficient in third party application integration to meet some of your end requirements. Hire a Drupal developer with expertise in,

  • Integrating with other third party applications, such as  CRM, ERP, marketing automation, logistics applications etc. which you may need to meet your business requirement. 
  • Data visualization and analytics tool that can be used along with Drupal in order to measure application/website efficiency.
  • Javascript frameworks to handle decoupled Drupal in case you choose that route.
     
Jul 16 2019
Jul 16

Despite Drupal 8 (D8) being launched back in 2015 and Drupal 9’s release date looming; there are almost a million websites on the internet still running on Drupal 7 (D7). However; many of the website owners justify their reasoning for sticking with Drupal 7 until now to the long update to Drupal 8 process and the budget required.

So... should you upgrade your website to Drupal 8 now? That really depends on your business needs… however; since you decided to build your website using Drupal, I assume you already know the unique advantages that Drupal brings to your brand’s digital experience. 

We take a look at a few logical reasons to upgrade your website to Drupal 8 sooner rather than later:

 

 

1. D7 End-Of-Life (EOL) Is Around the Corner

Both Drupal 7 and Drupal 8 versions will continue to receive support and fixes from the community until November 2021, a whole year after the release of Drupal 9 in 2020. Beyond that EOL date; D7 and D8 will no longer receive any support. What does that mean?

The community at large will no longer create new projects, fix bugs in existing projects, write documentation, etc. around Drupal 7. There will be no more core commits to Drupal 7. The Drupal Security Team will no longer provide support or Security Advisories for Drupal 7 core or contributed modules, themes, or other projects. Reports about Drupal 7 vulnerabilities might become public creating 0 day exploits. All Drupal 7 releases on all project pages will be flagged as not supported. Maintainers can change that flag if they desire to. On Drupal 7 sites with the update status module, Drupal Core will show up as unsupported. 

After November 2021, using Drupal 7 may be flagged as insecure in 3rd party scans as it no longer gets support. If you have a site that is running on Drupal 7, now is the time to start planning the upgrade. You don’t want to be making that decision with only a couple of months to the EOL date remaining.

If you still plan to stick to Drupal 7; you can engage the services of specific vendors who will be announced at a later date as officially recognized members of the Drupal 7 Vendor Extended Support program (D7ES).

Or, you could save money and time by upgrading now and gain the significantly richer benefits of Drupal 8. I strongly recommend this approach. Win-Win.

2. Power Your Digital Business

This one is logical. If you think you’d be saving money and time by jumping directly to Drupal 9 from Drupal 7, think again.

You are already missing out on Drupal 8’s awesome features. Drupal 8 was built with a focus on creating engaging user experiences. Website performance is at the core of all improvements, updates, and modules being created for Drupal 8. One of the first significant improvements introduced was Facebook’s BigPipe, which is now a built-in stable module in Drupal core.

Major brands that are running websites on Drupal 8 can give their site visitors the mobile-first, search engine optimized and secure user experience they crave. Businesses that cater to a global audience are reaping the benefits of the multilingual and translation tools built-in Drupal 8’s CMS.

From creating engaging dynamic webpages using the awesome Layout Builder module to a streamlined rich content publishing process. Drupal 8 boasts numerous modules that are a marketers dream

 

 

Additionally, Drupal 8 replaced PHPtemplate with a new, faster, simpler and much more secure theming engine, Twig. Though Twig is PHP-based, all that front end developers need to create beautiful websites is their skill in HTML/CSS. They don’t need to boast much PHP experience or expertise anymore.

 

The aforementioned are but a sample of highlighted features. Think of all the modules that have been improved and enhanced to build a digital experience that engages your base better than ever. Are you willing to be behind the pack until you decide I need to upgrade closer to the Drupal 7’s EOL date?

 

 

3. Smooth Migration to D9

Migrating your website from Drupal 6 to 7 demanded an entire rebuild. It’s true that migrating from Drupal 7 to 8 would be a major hassle as well, however, this would be the last major rebuild you will ever have to make again thanks to Semantic Versioning.

Drupal 9 is built on-top of Drupal 8. Hence, the transition when migrating from Drupal 8 to 9 will be seamless and effortless, especially when you compare the hassle of migrating between other major versions. 

Drupal 9 Release Timeline

“The first release of Drupal 9 will be very similar to the last minor release of Drupal 8, as the primary goal of the Drupal 9.0.0 release will be to remove deprecated code and update third-party dependencies. By keeping your Drupal 8 sites up to date, you should be well prepared for Drupal 9.” - Dries Buytaert, Drupal Project Lead

If you are still reluctant to rebuild your website in order to benefit from the sample of highlighted Drupal 8 features we mentioned earlier; consider Varbase.

Varbase is an enhanced Drupal distribution packed with adaptive functionalities and essential modules, that speed up your development, and provides you with standardized configurations, making your life easier. The essence of Varbase, lies within the basic concept that initiated it; DRY (Don’t Repeat Yourself). Varbase handles that for you, relieving you from repeating all the modules, features, configurations that are included in every Drupal project.

You can build a beast of a digital experience that caters for a global and diverse audience, search engine optimized and mobile-first; whilst saving over 200 development hours.

The time to prepare for your business’ digital future is now. Adopting a neutral stance is only going to be a waste of time, traction and money. Choosing to upgrade to Drupal 8 right now means that you have already upgraded to Drupal 9. 

Drupal’s focus on engaging digital experiences reflects the actual shift in user behavior in real life. That is the main reason why global brands and many industries such as the entertainment industry, higher education, healthcare, and even public sectors are adopting Drupal… and Drupal 8’s features offer your digital business more than you can begin to imagine. Our award-winning team can help you build a digitally thriving business in the future by guiding you through the upgrade process. 

Contact us now and get a thorough complimentary performance audit of your website!

Jul 15 2019
Jul 15

When sending email from your application, using queuing process can reduce the application response time and increase speed.

By sending the message to queue instead of sending directly at the end of server response, you may achieve better user experience. Once messages are in queue, you just need a scheduled cron task to initiate scheduled email sending.

How ?

Queuing is simple in Drupal 8

Jul 12 2019
Jul 12

The PHP version of Pattern Lab has been a trusty tool for a long time, especially for many of us working with Twig and component-based theming for Drupal. However, ever since a decision was made to focus development efforts on Pattern Lab Node, it has been clear that it would eventually become necessary to switch from using the PHP version to using the Node version.

Twig developers do not need to worry about compatibility, since thanks to the efforts of Evan Lovely and Salem Ghoweri, Pattern Lab Node now uses a PHP Twig renderer to render Twig templates. This means that templates are rendered using the official PHP implementation of Twig, and it is even possible to add PHP extensions to the Twig environment used by the renderer.

Pattern Lab Node 3.0 is the future of Pattern Lab, with many improvements over the PHP version, especially in the UI. However, it is still in beta and a bit rough around the edges. There have been issues with pseudo-patterns, and more work is needed to support plugins. With well-established development approaches based on the use of data files and plugins in Pattern Lab PHP, how can we make the switch to using the Node version?

A new approach

Limitations can often drive creativity. I do not know if that is the case here, but a great new development approach is being used by folks already using Pattern Lab Node. This approach was described by Evan Lovely in his excellent presentation ‘Pattern Lab: The Definitive How-to’, and is used by Aaron Froehlich and Jeff Amaral in Union, an inspiring project well worth checking out.

The basic idea in this new approach is to use a new type of template in Pattern Lab. These new templates provide demo data for the actual component templates, making traditional Pattern Lab JSON/YAML data files mostly unnecessary.

As an example, if we have a _heading.twig template (note the leading underscore, which hides the pattern in Pattern Lab)

<h1>{{ title }}</h1>

instead of creating a heading.yml data file

title: ‘Hello’

we create a heading-demo.twig template

{% include ‘_heading.twig’ with {‘title’: ‘Hello’} only %}

These demo templates are very similar to ‘presenter’ templates used in component-based Drupal theming, as they only process and pass data to the actual component templates, and do not contain any markup.

Pros and possible cons

Even though plugins like Data Transform Plugin can make plain data files more powerful, using Twig to provide demo data opens up a whole new world of possibilities. For example, demo templates can use Twig extensions that might not be acceptable in plain Twig components. I am certain that there will be a lot of innovation in this approach and related best practices in the future.

One possible drawback is that the Pattern Lab UI will display the Twig source of the demo template instead of the source of the actual component. However, it is only a possible drawback, as in many cases it might actually be useful to show how the component should be included from another template. And it is still possible to use a data file if it is important to show the source of the component itself.

A new version of Shila theme

I have been wanting to switch to using Pattern Lab Node for some time now, and this new approach has made it possible. I have refactored Shila theme, which I use as a starting point for all my Drupal theme projects, to use demo templates. This change makes it possible to use Shila theme with both Pattern Lab PHP and Pattern Lab Node. If you are interested in a full implementation of this new approach be sure to check out the new version of Shila theme.

Jul 12 2019
Jul 12

If you build Drupal 8 sites using the Drupal Composer/Drupal Project Composer template (DCDP), then you've likely noticed the development dependency webflo/drupal-core-require-dev. If you're like me, you probably didn't give it much thought the first 20 or 30 times you used the template. 

After a while though, I started to dig deeper into the details of DCDP, wanting to be able to understand exactly how it worked and what customizations I may want to make. DCDP was really my first real exposure to Composer, and the more I learned, the more I wanted to learn (as is often the case). My curiosity led me to this drupal-core-require-dev rabbit hole.

Some background

First, let's level-set ourselves - when you run either "composer install" or "composer create-project" (which is actually calling "composer install" as well) without the "--no-dev" switch, Composer will install all dependencies listed in your composer.json file in both the "require" and "require-dev" sections (as well as dependencies of dependencies). If you take a look at DCDP, you'll notice that in the "require-dev" section, there is one entry: webflo/drupal-core-require-dev. 

So, as most folks who start Drupal 8 projects using the recommended DCDP command listed in the README (composer create-project drupal-composer/drupal-project:8.x-dev some-dir --no-interaction), Composer is installing everything in the "require" and "require-dev" sections - including webflo/drupal-core-require-dev.

What exactly is webflo/drupal-core-require-dev? Well, it is a "virtual" dependency - meaning it doesn't include any code, rather it just includes a composer.json file that specifies the specific versions of Drupal core development ("require-dev") dependencies that are used to run Drupal core tests. The interesting (and sometimes problematic bit) is that webflo/drupal-core-require-dev doesn't specify any versions for non-development ("require") dependencies. If you take a look at Drupal core's composer.json file, you'll see that for the most part, specific versions of dependencies aren't specified - rather a range is. 

This leads to the situation where a project built with webflo/drupal-core-require-dev could have different dependency versions (as long as they adhere to the version constraints is Drupal core's composer.json) than what comes with Drupal core if you had just downloaded it from drupal.org.

For example, if on the date version 8.7.0 of Drupal core was released one of the development dependencies was at version 1.3.1, then that is the version that is provided with Drupal core 8.7.0 downloaded from drupal.org regardless of when you download it. But, when using the DCDP as-is, if since the release of Drupal core 8.7.0 the development dependency was updated to 1.3.2, then when the project is installed using "composer create-project", your project will be using version 1.3.2 of the dependency. While this seems minor, it has led to some issues

Also - be aware that there are different versions of webflo/drupal-core-require-dev for every minor version of Drupal core. So, if you're updating your site from Drupal core 8.6.x to 8.7.x, then you must also update to webflo/drupal-core-require-dev to 8.7 as well. This is the reason the update command for DCDP includes webflo/drupal-core-require-dev:composer update drupal/core webflo/drupal-core-require-dev "symfony/*" --with-dependencies

After learning this, I had an obvious question: what's the advantage of having Composer install updated versions of Drupal core dependencies? The only thing I found was that if you're a core or contrib developer, then it would be useful to know if your code breaks using updated dependencies. I'm hard-pressed to think of another reason when this makes sense. For most Drupal 8 projects, I think it would be beneficial to use the exact dependencies that the particular version of Drupal core ships with. This way, we can be 100% certain that our project has the same dependency versions that the community's testing infrastructure has validated for the particular version. Luckily, that's what webflo/drupal-core-strict is for. 

It works almost the exact same way as webflo/drupal-core-require-dev except that it includes exact versions for all dependencies of Drupal core - for both development ("require-dev") and non-development ("require") packages. The exact versions are the ones that have been tested and are included in the "official" version of Drupal core (for each minor version) downloadable from drupal.org. Like webflo/drupal-core-require-dev, there is a minor version of webflo/drupal-core-strict for each minor version of Drupal core.

So, why does DCDP use webflo/drupal-core-require-dev? Well, there's some debate about if it should or not. 

As a side-note, if you host on Pantheon, and use their Pantheon-flavored version of DCDP, then you're probably already using webflo/drupal-core-strict.

Starting a project with DCDP using webflo/drupal-core-strict

First, the bad news - if you want to start a new project using webflo/drupal-core-strict, you can't use DCDP out-of-the-(virtual)-box. But, there's a couple of possibilities. At first glance, it seems that you could fork DCDP, make the relevant change to webflo/drupal-core-strict in the composer.json file, then use "composer create-project" on your fork. But, this would also require posting your fork on Packagist (which is discouraged), updating your fork's README (for the create-project and update commands) as well as keeping your fork up-to-date with any DCDP updates. I wouldn't recommend this method.

A better option is to use the "--no-install" option of Composer's "create-project" command:

1.  Use the recommended command on the DCDP page, but add a "--no-install" at the end of it:

composer create-project drupal-composer/drupal-project:8.x-dev some-dir --no-interaction --no-install

This will download DCDP to your local, but not install dependencies. 

2.  Edit the composer.json file with:

  • New project name
  • New project description
  • Remove "webflo/drupal-core-require-dev" from the "require-dev" section
  • Add "webflo/drupal-core-strict": "^8.7.0", to the "require" section (ensure the version matches drupal/core).
  • Change the version requirement for drupal/console to: "drupal/console": "^1.0", (to avoid version conflicts)
  • Change the version requirement for drush/drush to: "drush/drush": "^9.0", (to avoid version conflicts)
  • Remove "composer/installers" from the "require" section (it is already specified in webflo/drupal-core-strict). 

3.  Run "composer install". 

You'll need to remember that when you want to update Drupal core, you'll want to use the following command (instead of what is in the DCDP README):

composer update drupal/core webflo/drupal-core-strict "symfony/*" --with-dependencies

If you're not crazy about either of these two options, there is a third (future?) - leave a comment on this issue and ask for webflo/drupal-core-strict to be used in DCDP. 

Change an existing project from webflo/drupal-core-require-dev to webflo/drupal-core-strict

What if you already have a project based on DCDP and you want to change it from using webflo/drupal-core-require-dev to webflo/drupal-core-strict? Here's some possible ways of doing it:

As always, to be safe, please test things like this on a copy of your project.

Method one: manually downgrade dependencies

This is definitely a tedious process. It involves first removing webflo/drupal-core-require-dev using:

composer remove webflo/drupal-core-require-dev

Then, attempt to require drupal-core-strict:

composer require webflo/drupal-core-strict:^8.7.0

Depending on a number of factors you're likely to get a bunch of "Your requirements could not be resolved to an installable set of packages." messages. How many you get is mostly a result of the length of time since the previous minor release of Drupal core - the longer it has been, the more dependencies have probably been updated. For each dependency listed, you'll need to downgrade it using something like:

composer require symfony/yaml:3.4.26

What is happening is that webflo/drupal-core-require-dev allows dependencies to get upgraded outside of the Drupal core release timeline, while webflo/drupal-core-strict does not. So, you'll need to downgrade dependencies that have been updated. You'll have to do it one-at-a-time - try requiring webflo/drupal-core-strict, see the error message, downgrade the offending dependency, then repeat. In some cases, it isn't immediately obvious which dependency needs to be downgraded, or which version it needs to be downgraded to, so be prepared to use the "composer depends" command a few times. 

Eventually, requiring webflo/drupal-core-strict will succeed and you'll know that you're done.

There is one major downside to this method though - by requiring specific versions of each dependency, the versions are effectively pinned in the composer.json file. So, the next time you update Drupal core (and webflo/drupal-core-strict), these specific version constraints will conflict with the updated webflo/drupal-core-strict. One solution would be to remove all of these dependencies from the "require" section of your composer.json file. 

Method two: rebuilding your codebase

If Method one is tedious and precise, then this method is more of a (less tedious) big hammer. Depending on the complexity of your codebase, this might be a better option for simpler projects. In short, make a copy of your composer.json (for reference), then use "composer remove" to remove dependencies on drupal/core, webflo/drupal-core-require-dev, and anything that depends on them. Then, use "composer require" to add back drupal/core and webflo/drupal-core-strict: 

composer require webflo/drupal-core-strict:^8.7.0 drupal/core:^8.7.0

Then, add back (composer require) all the dependencies you had to remove. Be sure to add back the same versions of each dependency (this includes Drupal profiles, modules, and themes!) to end up where you were when you started. Once everything is back, then you'll probably want to "relax" the version constraints of your dependencies in your composer.json by adding a "^". For example, if you re-add a contrib module using:

composer require drupal/pathauto:8.1.3

Then in the "require section" of your composer.json you'll have:

"drupal/pathauto": "8.1.3",

This will prevent drupal/pathauto from being updated. So, you'll want to change this to:

"drupal/pathauto": "^8.1.3",

Method three: delete and update

While researching this topic, I posted an issue in the webflow/drupal-core-require-dev queue and Greg Anderson was kind enough to offer another method:

[One] solution is to modify your composer.json file, attach the same version limit to drupal/core and drupal-core-strict (e.g. ^8.7.3) to limit what [composer update] needs to look at, and then [delete] both your composer.lock and your vendor directory and run "composer update".

One caveat about this method is that it will update everything. Any outstanding dependency updates (including Drupal profiles, modules, and themes) will be applied (unless you constrain them in your composer.json). Here's what Greg suggests:

  • Pin your contrib modules that are not updated to an exact version in composer.json.
  • Remove vendor and composer.lock, add webflo/drupal-core-strict [to your composer.json], and generate a new lock file [with "composer update"].
  • Remove the pins of your contrib modules in your composer.json by adding ^ [similar to the example in the previous method.]
  • Run composer update --lock

Method four: ???

Is there an easier way to do this? If so, I'd love to hear about it. Let me know in a comment below.

Which to use?

So which one should you use? If all your contrib projects are up-to-date, then I'd go with Method 3. If not, then I'd recommend Method 2 or 3 depending on which you're more comfortable with.

The future

Of course, in the future, much of this may be moot (for new projects, at least), as there is an active effort to bring an official version of DCDP to Drupal, including a new scaffolding dependency (committed to drupal/core on July 10, 2019!) and something akin to drupal-core-require-dev and drupal-core-strict. To find out more, check out the Composer Support in Core Initiative

Thanks to Greg Anderson, one of the Composer in Core Initiative coordinators, for his input and review of this article.

Jul 11 2019
Jul 11

Our lead community developer, Alona Oneill, has been sitting in on the latest Drupal Core Initiative meetings and putting together meeting recaps outlining key talking points from each discussion. This article breaks down highlights from meetings this past May. You'll find that the meetings, while also providing updates of completed tasks, are also conversations looking for community member involvement. There are many moving pieces as things are getting ramped up for Drupal 9, so if you see something you think you can provide insights on, we encourage you to get involved.

Drupal 9 readiness meeting! 07/08/19 

Meetings are for core and contributed project developers as well as people who have integrations and services related to core. Site developers who want to stay in the know to keep up-to-date for the easiest Drupal 9 upgrade of their sites are also welcome.

  • Usually happens every other Monday at 18:00 UTC.
  • Is done over chat.
  • Happens in threads, which you can follow to be notified of new replies even if you don’t comment in the thread. You may also join the meeting later and participate asynchronously!
  • Has a public agenda anyone can add to.
  • Transcript will be exported and posted to the agenda issue.

Drupal-check and Upgrade status updates

Drupal 7 migration path UX improvements to do

Started work on "create an audit plugin class/manager for migrations", in an attempt to provide a user interface for situations where the migration path can’t be determined without some input from the user.

Removing deprecated API uses from core

As per Drupal core's own deprecation testing results we have moved somewhat in the past month, therefore by resolving "Replace calls to format_string()" we could cut down to less than 50% of the current number. Previously we indicated that we are looking into core’s use of deprecated APIs as an indicator as to when the Drupal 9 branch could be opened, where we can do the actual Symfony update as well as PHP version requirements updates. Doing this so as to have a branch for people to test with sooner than later, there by resolving the deprecated API uses is in that critical path.

The roadmap for simpletest out of Drupal

  • A published roadmap for simpletest is live. 
  • There are a few issues here:
    • There's a module called simpletest in core that should be deprecated.
    • There's a class called TestBase which should be deprecated.
    • There's a simpletest UI that might end up living in D9 as testing_ui.
    • There's a test runner called run_tests.sh that needs to be refactored for all of the above.

Admin UI meeting (07/10/19)

Meetings are for core and contributed project developers as well as people who have integrations and services related to core. 

  • Usually happens every other Wednesday at 2:30pm UTC.
  • Is done over chat.
  • Happens in threads, which you can follow to be notified of new replies even if you don’t comment in the thread. You may also join the meeting later and participate asynchronously!
  • There are roughly 5-10 minutes between topics for those who are multitasking to follow along.
  • The agenda is public and anyone can add new topics in the document.

Permissions and other requirements for the new Content Editor role:

The "Add new Content Editor" role to "Standard Profile" issue is open.

The basic features we identified are:

  •   Create and edit new content - articles and pages
  •   Use the basic HTML text format
  •   View unpublished content
  •   Create and edit terms (tags and categories)
  •   Access the administration theme

One of the suggestions was to base Editor permissions on what Umami already set up and add all the permissions that are needed in all modules that come with core (even that they come disabled by default).

Review and approve the Roadmap to stabilize Claro

Issue "Roadmap to stabilize Claro" was opened.

Status of the tabledrag component

  • Table drag style update is in progress. From a design perspective, the current table drag and drop is good enough for a MVP(beta) Claro version.
Jul 11 2019
Jul 11

For the past several years (2016, 2018, 2019) Dries has written articles aimed at helping people decide if and how one should decouple Drupal; a general survey of the state of decoupled/headless Drupal. In his most recent post he mentioned the pace of innovation has been accelerating due to the number of Content Management channels and JavaScript frameworks to support. I’ve been particularly excited about the JavasScript frameworks and hoped to find more in-depth coverage of this.

Much to my chagrin, from numerous conversations with Front-End developers as well as other Full Stack developers, I’ve found that knowledge in the community about a lot of the innovations happening outside the traditional Drupal or Open Source world has not grown as fast. Much of the content being published, in my opinion, doesn’t necessarily do a great job of covering some of the better possibilities out there and potentially leave readers and attendee’s of talks un-informed on just what the possibilities are.

Understandably, everyone can’t be expected to know everything about everything, but I believe there’s an opportunity for the community to leverage some of the powerful tools that exist with the knowledge we have to increase the use case for Drupal.

Show ‘Em What We’ve Got

Today, unlike the days of yesteryear, many members of the community are already equipped with the tools to build truly native mobile applications thus eliminating the need for Java or Swift since JavaScript and TypeScript based languages can be just as effective. 

In the interest of raising more awareness of what’s out there, I’ve decided to explore some of the most popular frameworks for building native mobile apps from a single codebase using technologies familiar or learnable by many. With that, I’ll be exploring their ease of integration with Drupal.

Exploring The Possibilities

Over the next several months I will explore and evaluate some of the tools available for native mobile app development, as well as Drupal tools, modules, and distributions that facilitate this. I will also go through the process of building actual apps to provide insight into the research you may not have the time to do yourself. 

The tools I will explore, in addition to core and contrib Drupal modules, will include:

  • ContentCMS (API-first Drupal distribution)
  • ReactNative (Framework for building mobile apps with ReactJS)
  • Tabris (Framework for building native mobile apps with JavaScript or TypeScript)
  • NativeScript (Framework for building native mobile apps with JavaScript, TypeScript, Angular or VueJS)
  • Appcelerator Titanium (Framework for building native mobile apps with JavaScript)
  • Fuse (Framework for building native mobile apps with JavaScript)

My hope is that by the end of the series, there might be a few converts to Drupal-powered native mobile development both from the Drupal side and from the frontend development side. WordPress is already ahead of Drupal on this with several plugins that convert WordPress sites into native mobile apps, so we have some catching up to do.

Jul 11 2019
Jul 11

On September 12–14, at Hilton Garden Inn Atlanta-Buckhead

Kaleem Clarkson Kyle Mathews, 2019 DrupalCamp Atlanta Keynote

This year, DrupalCamp Atlanta is honored to welcome Kyle Mathews as our keynote speaker, creator of the open source project Gatsby. Gatsby was a hot topic at DrupalCon this year, and we’re ready to dive into the software at DrupalCamp this September.

Follow Kyle on Twitter and Github.

Session submissions are now open for DrupalCamp Atlanta 2019! With Kyle as our keynote, we’re interested to see how others are combining Drupal and Gatsby. In addition, we’re also accepting sessions in the following tracks:

  • Beginner
  • Design, Theming, and Usability
  • Development and Performance
  • Site Building
  • Business Leadership
  • Education and Training

Each session is 40 minutes with 10 minutes for Q&A. Each room will be set classroom style and will have a projection screen and with in house audio.

Trainings

In addition to 50-minute sessions, we’re also looking for volunteer trainers for our full day of trainings on Thursday (9/12) and a half day on Friday (9/13). Training sessions can range across all experience levels. You can submit your call for training here.

One of our goals for this year’s camp was to increase the number of case studies. We encourage web development companies and units to connect with their clients to co-present a session at this year’s DCATL.

We see this as an opportunity to re-engage with a client by highlighting the great work you have done together all while introducing them to the awesome Drupal community we have. So, reach out to some of our clients and propose a presentation today!

SUBMIT YOUR PROPOSAL HERE

Jul 11 2019
Jul 11

Existing Values Autocomplete WidgetProviding the content creator a field with a list of values to choose from is a common requirement when building a Drupal site. It’s also something that can be achieved in a variety of ways, each having pros and cons to the approach. Texas Creative’s web team has developed a module that we believe fills a missing gap in this type of field called Existing Values Autocomplete Widget.

In the following analysis, we will discuss each possible approach, the use case for it, along with an example. The final approach includes using our new module. 

1. Taxonomy Term Field

The approach with the most flexibility and functionality, but also the most overhead and potentially unwanted “features”, is to create a new Taxonomy Vocabulary and use a Taxonomy Term Field to allow the content creator to choose from the list. The user can create/manage terms easily. However, each term will have its own “page” that displays every node that uses that term. If you don’t want that, it can be dealt with using the rabbit hole module among others, but it will have to be dealt with on some level. There is also some overhead added to the system in terms of additional code and additional database calls/joins for this extra layer of functionality.

Criteria:  If your use-case can leverage the “relationship” of the taxonomy term and the display pages that are created, then this is the best choice.

Example: Company Departments: They may change in the future and you may have an interest in associating many content types to the departments in order to aggregate them on a single landing page for that department.

2. Text Field (List) with Allowed Values

A simpler approach, with some serious limitations, is to provide a simple text field (list) and populate the ‘allowed values’ with all possible values needed. The advantage here is the simplicity of setup, assuming you have a small well-defined list. In most cases, the content creator will not be given permission to add/change allowed values, so the developer will need to facilitate any future changes to this field. Additionally, it becomes difficult to “remove” options since there are values assigned to them already so Drupal will not allow those deletions. 

Criteria: If the list of values is small and unlikely to be changed, and you are not interested in the “relationship” aspect of taxonomies, then this is a good option.

Example: Outcome Status like (Sold, Returned, In Inventory, Backorder): This is a small, rarely changing list so the additional hassle of managing the list is not a concern and we would not be interested in the “relationship” to this value. You would only be likely to display this status or have it as a filter option on a list of nodes both of which are possible with the text field.

3. Text Field with Existing Values Autocomplete Widget

At Texas Creative, we often find ourselves in the middle of these two approaches. We want a simple field without all of the taxonomy overhead and complexity, but the list of values is not known or finite, so the client needs to be able to add new ones easily. The Existing Values Autocomplete Widget was born to fill this gap by providing a way to pull any value previously entered in the text field as an option on the fly. This module creates a new field widget for text fields with autocomplete suggestions using previously entered values.

Drupal 8 Render API allows for an autocomplete callback to be registered on a render array’s element. Then the Render API handles all the AJAX. The module provides a controller, as the autocomplete callback, responsible for returning the autocomplete suggestions to the field widget.

Criteria: If the values are unknown or unlimited, and you’d like to reduce most of the duplication of similar values, then this approach finds a happy medium.

Example: Park Amenities: The values of this field could vary widely across the parks but it would be helpful to use the same wording for similar amenities such as Playground, Paddling Trails, Disc Golf, etc.

Instructions for Using the Existing Values Autocomplete Widget

  1. Install & enable module per usual process.
  2. Visit any content type ‘Manage Form Display’ page.
  3. Change “Textfield” widget to “Autocomplete: existing values”.
  4. Configure how many suggestions to show in the widget configuration. (default: 15)
  5. Enter values in the field and they will become suggestions next time.

Advice that is often given in the Drupal community is that you should get involved by “scratching your own itch”, meaning solve the problems and use cases that bother you.  An important part of that is to then share your solutions. It is inevitable that someone else has the same “itch” and may not even realize it until they see your solution. The Existing Values Autocomplete Widget is the most recent example of this for the Texas Creative web team.  We like solving problems from the simple to the complex. We also like knowing when our solutions helped someone else. Please comment below if you find this post or module useful, and join us in the issue queue with any bugs or feature requests. You can also see our team’s Drupal contributions on our organization page.

For more Drupal knowledge from the Texas Creative web team check out our other blog posts on web development topics.

Jul 10 2019
Jul 10

The countdown for the June 2020 Drupal 9 release has begun. As the Drupal community awaits this next big thing, here are the two burning questions on the minds of Drupal Devotees: 

  • What can we expect from Drupal 9?
  • What should we do between now and next June?

As the Business Development lead for Promet Source, with the added perspective of an Acquia Certified Drupal 8 Site Builder, I’m in the trenches everyday helping organizations to unpack questions such as these. Here are some of the concerns that I hear most often, along with my thoughts on how to most efficiently prepare for the transition.

Q. What are the most exciting/game-changing features of Drupal 9?

The most exciting thing about Drupal 9 is that there aren’t any game-changing features! No new features will be added after Drupal 8.9. Drupal 9 will remove any depreciated code or APIs that are still in Core. If your site works great on Drupal 8.9 and you are not relying on any depreciated APIs, the upgrade to Drupal 9 should be just like going from Drupal 8.8 to Drupal 8.9.

Q. To what extent does Drupal 9 reflect the evolution of the Drupal community?

Many of us know about the pain of migrating from Drupal 7 to 8. In fact, it is so painful that 750,000 Drupal 7 sites still haven’t upgraded. Drupal 9 represents the cumulation of the vision implemented with the complete overhaul that resulted in Drupal 8. For all practical purposes, Drupal 8 is a different CMS than Drupal 7. However, Drupal 8 was built with the idea that future major version upgrades would be incremental, not evolutionary changes. Drupal 8 is a enterprise-ready CMS built to support engaging digital experiences over the long term.

Q. Do you anticipate that Drupal 9 will draw in new types of users?

I don’t expect Drupal 9 to be a major event at all, and that is a good thing. It’s simply what comes after Drupal 8.9. Some changes in Drupal 8 over its lifespan, particularly the Layout Builder features that enables very powerful drag-and-drop page building capabilities, should make Drupal more appealing to distributed organizations that want to distribute content creation and management throughout the organization.

Q. Why would we migrate from Drupal 7 to Drupal 8 at this point when another migration is around the corner?

Change is inevitable. You can’t avoid it. Drupal 9 is really just the next update after Drupal 8.9. In fact, it will have feature parity with Drupal 8.9. Migrating from Drupal 7 to Drupal 9 will be no more or less complicated than migrating from Drupal 7 to Drupal 8. Also, Drupal 7 and 8 will both hit end-of-life status at the same time, in November 2021. So staying on Drupal 7 or Drupal 8 won’t really be an option after November 2021.

The Drupal community won’t be maintaining Drupal 7 or 8 after Nov. 2021, although a  commercial vendor will likely seize the opportunity to provide a commercial support option. 

But really, just upgrade. Drupal 8.9 is so much better than Drupal 7 in many ways. Email me if you want to set up a call to discuss the differences.

Q. Practically speaking, could you compare a D7 to D8 migration, vs. a D8 to D9?

Imagine you drive a Toyota Camry and fortune smiles on you and are gifted a 2019 Ferrari 488 Pista. It’s still a car, but you will basically need to relearn how to drive. That is D7 to D8 from the developer perspective. The content editor/writer perspective is more like going from the Camry to a BMW. It’s just a nicer version of what you already had.

D8 to D9 will be like taking the Ferrari in for a tune-up.

Q. We’ve already migrated to Drupal 8 and it meets our needs. Any reason why we can’t just leave it at that and stay with Drupal 8 indefinitely?

Drupal 9 is just the update that comes after Drupal 8.9. For all practical purposes, you are staying on Drupal 8. It's just that Drupal 8 is constantly evolving, and because we are out of single digit number to the right of the decimal point at 8.9, the next update gets called Drupal 9.0. Also, that change in digits is a convenient place to clean out the depreciated code in the code base that you should have stopped using by now anyway.

We at Promet Source are here to help with any Drupal-related questions that you might have. Contact us anytime.


 

Jul 10 2019
Jul 10

Kanopi Studios is honored to have contributed to Mukrutu, a project that offers a powerful example of the importance of putting inclusivity, cultural sensitivity, and user needs at the center of design and development so that technology can be used as a force for good. 

What is Mukurtu?

Mukurtu  (MOOK-oo-too) is a free content management system built with Drupal that helps indigenous communities manage, share, and exchange their heritage in culturally relevant and ethically-minded ways.

“Mukurtu” is a Warumungu word for safe keeping place, a name chosen in 2007 when Warumungu community members collaborated with developers and scholars on the first iteration of the platform to produce the Mukurtu Wumpurrarni-kari Archive.

Surviving cultures risk being drowned out or forgotten by modern society due to dwindling numbers, resources, and legal claim to land and heritage. By sharing their voices, indigenous cultures can preserve their history and way of life, educate others, and seek much-needed support. But by doing so, they run the risk of losing control and ownership of the narrative. The Mukurtu project helps to solve that problem. Mukurtu was created to allow indigenous cultures to share their heritage on their own terms, eliminating the potential for exploitation or misrepresentation. 

The power of Mukurtu comes from its complex and layered permission system that goes far beyond the capabilities of traditional content management systems. The system is purpose-built to allow indigenous people to maintain control over how information is shared, who they share it with, and how it can be used.

Mukurtu and Kanopi Studios

As the program expanded, Kanopi Studios joined the Center for Digital Scholarship and Curation at Washington State University and CoDA as a development partner. Kanopi led a research-guided approach that included focus groups and surveys with users to inform the project’s technical strategy and development.

Since Mukurtu’s original release, Kanopi has played a lead role in development, adding features based on user requests and ensuring that the system remains easy to use, secure, and scalable. New features include an improved  mobile experience and robust collaboration capabilities with a mobile app coming soon that will allow users to browse and add content from the field, even while offline. 

Kanopi Studios also works directly with clients who want to use Mukurtu, but need to enhance the system to meet unique needs. Custom development examples include a site to help relocate indigenous people in Kivalina, Alaska, another to share the voices of Amiskwaciy people in Edmonton, Canada, and one of our earliest projects with Washington State University.

How Mukurtu can support indigenous communities 

Mukurtu was built to be flexible enough to support diverse communities while remaining easy enough that non-technical users can add and update content and permissions.

Core features include:

  • Traditional knowledge labels allow communities to add labels to content that describe how that content can be accessed, used and circulated, and to whom it needs to be attributed.
  • Cultural protocols allow for finely-grained content access settings that can be customized on an ongoing basis to meet the needs and values of each community, from wide open, to restricted at the individual level. 
  • Community records allow multiple ways to store information about cultural heritage so critical details and diverse perspectives can be maintained. 
  • Data integrity uses file hashes to ensure that files are not tampered with, ensuring that content remains intact over time.
  • Dictionary helps indigenous communities preserve their language, complete with translations, definitions, pronunciations, audio recordings, and other media
  • Collaboration tools allow site members to share events on group calendars and engage in threaded discussions.
  • Unit plans and lessons give educators and students a platform to engage in online and field learning through a Mukurtu site.

Indigenous communities across the globe use Mukurtu to record, preserve, and share their heritage, including the Plateau Peoples’ Web Portal, Passamaquoddy People, Catawba Indian Nation Archives, and many more. 

Impacting our future

While indigenous people benefit from sharing their stories, modern society has much to learn from their cultures as well, from our relationship to the land in a time when climate change threatens us all, to staying connected during this time of individualism and political divide. We’re proud to continue expanding Mukurtu as a platform for telling these important stories and hope they will help us build a stronger future for everyone.

Getting started with Mukurtu

If you have technical support and hosting available, you can download Mukurtu on Github and begin using it for free. For clients who need technical support additional customization of Mukurtu, contact us. We’d love to help.   

Jul 10 2019
Jul 10

AMSTERDAM July 10 2019 

The Splash Awards celebrate the best Drupal projects around the world by putting brands and agencies using Drupal center stage. Organized in different regions by local Drupal communities, the Splash Awards have become noteworthy to both insiders and outsiders of the Drupal community. With more and more countries organizing their own Splash Awards and the second edition of the International Splash Awards taking place at DrupalCon Amsterdam in October 2019, establishing a solid and open source brand is imperative. That is why the organisation introduced its new brand this week.

Splash Awards Brand - Poster Example

In 2014, the first Splash Awards was organized in Amsterdam. While several internet awards were already on the marketing-radar of agencies and brands alike, none had the open source characteristics that our community is accustomed to. Moreover, the need for Drupal to have a hallmark award of its own was evident. This put Drupal further on the map of journalists and media as well as potential Drupal users, highlighting Drupal’s many showcases. Equally important, it puts brands using Drupal center stage and welcomes them (further) into the Drupal community. 

Open Source Awards

True to its open source nature, the Splash Awards were adopted by volunteers from other Drupal communities and organized in various countries. In 2018 the first European Splash Awards was organized during Drupal Europe in Darmstadt, Germany. This opened the Splash Awards to the European Drupal community attending the event. In April 2019 the first International Splash Awards, targetting a global audience, took place in Seattle during the largest Drupal event in the world, DrupalCon. 

Inclusive

In order to serve as a strong and sustainable Drupal showcase platform, the Splash Awards brand needed a consistent and future proof brand. Flexibility, inclusiveness and open source were key in designing the brand, allowing cultures and regions to adopt and start organizing their own Splash Awards. The new brand  also offers flexibility to adapt to regional needs. The open source brand kit will help communities in organizing their own Splash Awards and at the same time it ensures consistency and recognition both inside and outside the Drupal community. 

DrupalCon Amsterdam

The volunteers team involved in the rebranding will also organize the next international Splash Awards during DrupalCon Amsterdam. The awards will take place on the first evening on Monday October 28th 2019. DrupalCon is the biggest Drupal conference in the world, having over 2000 Drupal professionals and users attending. The team works in conjunction with the Drupal Association and Kuoni, the organizations behind DrupalCon. 

With the Splash Awards gaining momentum, it has the unique opportunity to put Drupal in front of new business audiences. Brands  using Drupal proudly stand testimony to others about what a great digital experience platform they have, backed by a professional and passionate community. Drupal developers, agencies and brands can all take pride in winning this prestigious award, built on open source values and celebrating.

Find out more at https://www.drupal.org/community/splash-awards and splashawards.org (new website will relaunch on the coming weeks). You can also check out the new brand guide here.

For more information please contact:

Imre Gmelig Meijling (NL)
Baddy Sonja Breidert (DE)
Jeroen van den Berg (NL)
Nick Veenhof (BE)
Or [email protected]

Jul 10 2019
Jul 10

At last month's DrupalJam XL in Utrecht, the Netherlands, I gave Gabor Hojtsy's presentation on the state of Drupal 9. It was recorded - thanks DrupalJam organization! - so here is the video. You might also want to view Gabor's own presentation from DrupalCamp Belarus.

You'll need to turn up the audio, because it seems that it was recorded using the camera, not the fancy microphone I'm wearing.

[embedded content]

Jul 09 2019
Jul 09

The time has come, the time is now!! It’s time to register for the 13th annual Bay Area Drupal Camp!

At BADCamp, you'll get a chance to learn from the best, see old friends, make new connections, and walk away refreshed, inspired—and a little bit smarter, too.

Join us for four days of talks, training classes, summits, contributions, and socials with some of the brightest minds from all over the planet!

Register and sign up for the newsletter today!
 

Jul 09 2019
Jul 09

This was a 90 minute session from DrupalCon Seattle 2019. The room was not recorded :( BUT, we recorded locally from Mike’s laptop! Enjoy! Our slides are also attached in the links below. The room was overflowing and we got great feedback on it so I hope you enjoy it too

Seems that it was pretty well received given this tweet of me floating around jumping up and down :)

Amazing and entertaining session about web components @btopro :thumb: pic. twitter.com/kvzyl7SANw

– Abdelrahman Ibrahim (@IAboEyad) April 11, 2019
Jul 09 2019
Jul 09

In our previous blog - Demystifying the Decoupled Architecture - we discussed how decoupled architecture has become an increasingly popular choice to build enterprise-grade websites.

With various choices available, Drupal gives a breakthrough experience offering powerful content modeling, workflow capabilities and UI creation, helping evolve the marketing, branding and lead generation efforts.

Gatsby js, a React-based site generator, is a great option with Drupal for a decoupled architecture. Drupal and Gatsby form a powerful combination and here’s why this is a great choice.

Why Gatsby?

Let’s learn about the features of Gatsby which makes it an ideal match for decoupling with Drupal.

1. Plugin usage makes life simpler

Plugins help make the site offline, add Google analytics and supports inline SVGs, and much more, making Gatsby extensible and flexible.

Of the different types of Gatsby plugins, the gatsby-source plugins fetch data from a local or remote source and allow it to be used via GraphQL. This implies that almost anything can be used as a source to work with Gatsby and generate static sites.

Some plugins may need only to be listed by name, while others may take options. Gatsby plugin library offers a large number of plugins and continuously being maintained by the community.

2. Progressive Web Apps out-of-the-box

Gatsby enforces best practices to boost performance and add to the smoothness of user experience to give its site users an app-like experience.

The build process creates static HTML files for individual pages which offers swift loading of pages.

Gatsby boots up React on page loading on browser and navigates around your site to give you a single page application experience with near-instant transitions without page reloads. It works by prefetching related page content in the background to nullify any chance of delay on user click.

Gatsby exceptionally improves the client-side experience with JavaScript and can offer offline support with the addition of a single plugin.

3. JAMstack setup

JAMstack setup has taken the web development over by a storm with client-side JavaScript, reusable APIs, and prebuilt Markup offering a great combination to improve the speed and quality of your site as well as the overall developer experience. Gatsby acts as a JavaScript framework for a JAMstack-powered web application.

4. Built with performance in mind

Gatsby framework is built in a way to optimize the website performance on its own and compiles the most performant Webpack configuration to build your site once you create the source code.

It functions by prefetching resources to give a worldclass surfing experience to website users. It follows Google's PRPL (stands for Push Render Pre-cache Lazy-load) architectural pattern which aims to boost your website's performance, especially on mobile devices. The pattern is helpful for structuring and serving progressive web apps (PWAs). You can create PWA with Gatsby by running your page via HTTPS and installing a plugin for the manifest and service worker.

5. Easy to Use and Learn

Gatsby is based on React.js which is a JavaScript library for building user interfaces using components. It's relatively easy to learn, and if you’ve command over JavaScript code, you're good to go.

Working with Gatsby doesn’t require you to learn everything from scratch. Also, you can master working with it even if you don’t have experience working with React or GraphQL. Gatsby has a vast and active community to help you with your concerns.

Benefits of Decoupling Drupal with Gatsby

Static site generators like Gatsby pre-generate all the pages of the website unlike dynamic sites which render pages on-demand alleviating the need for live database querying and running through a template engine. This enhances the performance and brings down the maintenance cost.

Static site generators have seen a growth spurt over the past few years and have been the first preference of developers who wish to build a simple website/blog solution with a minimal server setup and a low maintenance cost.

Drupal proves to be a powerful back-end and is preferred by content editors for its WYSIWYG editor and content types which help them manage content more easily and systematically. However, maintaining a CMS requires hosting a web server and database, which poses security vulnerabilities.

diagram_gatsby_drupal

                                                                     Gatsby in action (Source: Gatsby.org)

Gatsby stands in between the robustness of static site, and the versatile back-end of a content management system. It allows you to host the CMS in-house and publish the content as a static website.

Watch the video to understand how Gatsby helps create blazing fast websites with Drupal:

Headless Drupal- Building blazing-fast websites with React-GatsbyJS + Drupal

Development approach

Gatsby, being a static site generator, lets the public folder created during the build time to behave as a static website.

To make it serve the requests, you can take that folder and deploy it on any server with Apache or nginx like server. Once the build is done, you can down your Drupal server and just deploy the public folder generated during the build.

 

null

 

This means that your Gatsby site will communicate with your Drupal backend during the build time, fetch all the details necessary and create static files for all the paths that will be present on your site.

 

With enterprises choosing to opt for more scalable and flexible experience, the popularity of Gatsby is increasing manifolds.

Are you thinking to implement best decoupled strategy for your next project? Contact our experts to get the best solution tailored as per your needs.

Jul 09 2019
Jul 09

open waters

In this episode of Open Waters, we talk with our own Bob Kepford, creator of the weekly newsletter The Weekly Drop, to discuss Open Source Serverless solutions.  Bob presented this topic at DrupalCon Seattle and it was very well received.  You can catch the recording on the DrupalCon site.

Audio Download Link

Pro Project Pick: Serverless Framework

Interview with Bob Kepford

  • The big question: What is Serverless?
  • What are the 4 pillars of serverless?
  • What are the advantages and disadvantages?
  • What do I have to know to get started?
  • As a site owner, why would I consider using serverless?
  • What are the security implications when using serverless?
  • Who are the big players who are adopting and/or providing serverless solutions?

Subscribe

Apple PodcastsStitcher | Google Podcasts

Jul 09 2019
Jul 09

Our great “drop” keeps moving to the future. While we are enjoying Drupal 8’s benefits, it’s already time to start preparing for Drupal 9. And every single contribution makes Drupal move faster and get better! 

We were interested in what Drupal experts and contributors think about Drupal. So we decided to ask 10 of them 3 questions in a blitz interview. We are very grateful to each of them for their answers and happy to share them with you.

These experts work with Drupal every day, maintain big or small Drupal modules, fix issues, speak at conferences, take part in code sprints, or mentor younger talents. Each of them contributes in their own way, but they are all united by the fact that they love Drupal and know it from the inside. This makes their thoughts especially valuable. So let’s go.

What Drupal contributors say about Drupal

Matt Glaman (mglaman)

  • What do you think is the greatest Drupal benefit?

The greatest benefit using Drupal is the community and the opportunities the community brings. The community is not just the people building Drupal but all of the businesses using and building with Drupal — from freelancers, to agencies, to clients. Once I started working with Drupal, the community has opened so many doors. 

Freelancing on the side brought me to DrupalCamp Atlanta, my first Drupal event — ever. I got hooked. Eventually attending the Milwaukee meetup and making connections led to a referral which let me move on from my agency work to a company building a web hosting platform using Drupal. Through active contributions I ended up with an offer to join Commerce Guys, now Centarro, and am looking forward to marking my fourth year with the company.

Through Drupal I have had the pleasure of making friends across the United States and the world. I have traveled to places I never imagined I would be, nor that I would have been able to visit Europe. Working with Drupal has changed my life and provided some amazing experiences.

  • Do you have a favorite Drupal module?

I am biased, but my favorite module is Drupal Commerce. My first Drupal site was an e-commerce site and I installed Commerce Kickstart. Drupal Commerce has been my point of reference for code since my earliest days. There is always an example for some kind of use case or problem solved.

Developing Drupal Commerce also provides interesting challenges. It has driven development of various popular contributed modules (Address, Profile, Entity, Inline Entity Form in Drupal 8 alone).

  • What do you expect from Drupal in the future?

I expect Drupal to become the flagship open source CMS used for robust experiences. We are going to move up in the market and lose some users. But we are going to gain more at the same time. Drupal needs to — the bottom market is being taken over by static site generators, not just WordPress or Squarespace. 

There also aren’t many open source eCommerce + CMS options out there. I am excited for the future of Drupal and Drupal Commerce for a fully integrated content, marketing, and ecommerce package.

Jacob Rockowitz (jrockowitz)

  • What do you think is the greatest Drupal benefit?

Many people would say "Community", but I feel that the community's "Collaboration" to create great software is Drupal's greatest benefit.

  • Do you have a favorite Drupal module?

The module which I have installed on every single Drupal site I have ever built is Honeypot, which mitigates spam form submissions using the Honeypot method. It is a reliable module that does exactly what it is intended to do, with great support from Jeff Geerling (geerlingguy) and the Drupal community.

  • What do you expect from Drupal in the future?

To accomplish some of Drupal's ambitious goals and initiatives, we are going to completely rework some old, outdated APIs and code. While improving or redoing Drupal APIs, I am optimistic that the Drupal community can collaborate and devise solutions that impacts and solves problems and challenges affecting all Open Source projects. More organizations will have to step in to lead and fund different initiatives to help make Drupal and Open Source more sustainable.

Mateu Aguiló Bosch (e0ipso)

  • What do you think is the greatest Drupal benefit?

It's difficult to choose one, but I think my favorite feature is the flexible yet robust way Drupal allows you to define any data model. It's the best content modelling tool for a CMS I have tried or heard of.

  • Do you have a favorite Drupal module?

There are many fantastic modules out there. All serve a specific purpose. My favorite is the one I need at any given time.

Among the ones I wrote, I have devoted a lot of time to JSON:API, but now that one is in core I'm turning my face towards Simple OAuth.

  • What do you expect from Drupal in the future?

To stay relevant for 20 more years. For that we need to make an effort to become more multi-channel and less web-specific.

Nick Veenhof (Nick_vh)

  • What do you think is the greatest Drupal benefit?

The greatest Drupal benefit is the ecosystem that is thriving around it. It is a massive pile of code snippets and working proof of concepts that you can take inspiration from, and on the other hand it is full of really stable, mature modules to build your base application on. The fact that it is can output not just html but also json for every resource is mind-blowing.

The reason why I stayed with this technology, and it sounds like a cliche, is the community. I’ve been involved in the Drupal ecosystem for over 12 years and it is has been a guide in my life. I started in Belgium and was welcomed in this community. Not much later I moved to Spain and was welcomed with the same open arms as I encountered before in Belgium. I repeated this pattern 2 more times in Portugal and Boston and from all these encounters I made quite some good friends. Not only in the community events but also as colleagues.

Drupal not only stays relevant when it comes to technology, it also thrives because there is more to it than technology. This is unique.

  • Do you have a favorite Drupal module?

I do not have a favourite module but I have a favourite ecosystem within Drupal. If you look at my profile you will see a pattern arise and that is Search. I did my Master-thesis around Drupal and Solr and if you look deep enough in my github account you can still find some gems in there. I’ve helped with upgrading Search API and Search Api Solr and all others to Drupal 8 and it is dear to my heart. I love the interoperability that it offers you to connect Drupal to Solr but also to connect external datasources to Drupal. It acts like a gate that reaches way beyond just search. Due to this reason and the people that have been crucial in this ecosystem this set of modules are my favorite. Also, not to forget, because of these modules I’ve been involved early on in Drupal 8 and got ahead of the curve in terms of knowledge and gave me a boost in my career for sure. I can recommend everyone to not just have a favorite module but to actively participate in an ecosystem or a specific module. 

  • What do you expect from Drupal in the future? 

My expectations are that extending Drupal for Content Editors/Marketeers will have to become a lot easier. Automatic updates are a massive pain but will have to be solved someday for Drupal to break out to the masses. What I think is that site builders can somehow have access to an App-Store’ish thing to more independently add functionality to their website. This will be supported by either a DIY solution or by companies like Dropsolid, Acquia or others. The work that is being done for the automatic updates, or even the work that is in the works from the association (Drupal Steward) leans very much towards these mechanisms already. Automatic updates first, adding of functionality next.

Balazs Janos Tatar (tatarbj)

  • What do you think is the greatest Drupal benefit?

“Come for the code, stay for the community.” After being in the Eastern part of Europe, visiting DrupalCamp Belarus and right after the DrupalCamp Kyiv ‘19 conferences, I couldn't be more happy to see how local communities make this saying an unquestionable truth. Sometimes people don’t fully understand what is written in the code, because of having less experience or just simply being a newcomer on the field: the Community behind Drupal is one of the strongest arguments that we always can use when promoting the project and involving newer pair of eyes and hands.

For me personally, working in the Mentoring Team, helping first timers to step up and start their contributions, guiding experienced ones to mentor others and supporting event organizers to shape a ‘Contribution day’ at their local camps always give me the joyful moments.

Earlier this year we started to promote mentoring activities by asking local events and their contributors who help others doing dev or non-dev contribution to the Drupal project to step up and let the Community know what did the do! In the Mentoring project in drupal.org, we have dedicated issues for all Drupal events this year. One of our goals is to get in touch with mentors who we might not yet know personally and hopefully meet them at DrupalCons, being part of the Mentors and have a truly unique experience when we all show our passion: Staying for the community.

  • Do you have a favorite Drupal module?

It’s a quite tricky question :)

Being not a coder for a while, but a security researcher, helping the Drupal Security Team with reporting issues and also acting as a regular speaker, wearing the (apart of many others) hat of a provisional member, my favorite Drupal modules are the ones that have a stable release and hosted on drupal.org.

You might ask why? It’s easy to answer: These are the contributed projects that have coverage by the Drupal Security Team.

Whenever someone finds a vulnerability in them, it’s going to go through a procedure and will be released in a coordinated way, one of the coming Wednesdays. Out of the security team members, the reporter(s) and the maintainers of the project, no one else know about the issue before it gets publicly disclosed, following our Disclosure Policy.

Apart of having a few contributed modules where I’m the maintainer (everyone loves their own children, right?) I would highlight the modules where I’ve reported issues and say thanks to all maintainers who helped fixing vulnerabilities and acted super professionally in the private queue — it’s never a blaming game when there is a security bug in a contrib but a great possibility to learn how it could be fixed in a secure fashion.

So overall, I would say my favorite Drupal modules are where I could have been involved to make them more secure: Facebook Like Button, Skype status, Yandex.Metrics, Mosaik, Cloud, bootstrap_carousel, Feedback Collect, Node feedback, ComScore direct tag, Taxonomy Term Reference Tree Widget, FileField Sources, Entity Reference Tab / Accordion Formatter, SVG Formatter, Entity Delete, XML Sitemap, PHP Configuration, NVP field, AddToAny Share Buttons and Back To Top - Thank You All to be responsive and kind with me during the period of remediation and even later, meeting in real life at Drupal events!

  • What do you expect from Drupal in the future?

I see many local communities that work hard to be recognised and their core teams to show why they love Drupal.

The Community Working Group (CWG) states they are present to maintain a friendly and welcoming community for the Drupal project (source). They appreciate the work that individuals do for the Community by maintaining the Aaron Winborn Award. This year I had the honor to give the Mentoring t-shirt to Leslie Glynn at our Mentor Booth at DrupalCon Seattle before she got the Award and it made my eyes wet seeing her on stage the next day. She is a perfect example for all of us about humanity, respect, kindness and overall commitment to the Community. Congrats and Thank You, Leslie!

Apart of many successful stories that I see in the Drupal project, one of the best is to see people stepping up and helping each other to contribute. AmyJune Hineline is one of the many Mentors who is not a technical person, shows us an awesome dedication to the Drupal Community. It makes me believe that the future of Drupal depends on individuals and their activities: come and be part of it at DrupalCon Amsterdam this October and “Get ready for another level of awesomeness!”.

Bram ten Hove (bramtenhove)

  • What do you think is the greatest Drupal benefit?

Being able to serve both site builders and developers. This is a tough balance to maintain, but Drupal seems to be doing this quite well.

On one hand site builders are able to create Drupal sites that are relatively easy (once you get the hang of it) to set up and configure. And on the other hand there is a lot of freedom and extensibility available for developers, making it a great choice for many organizations.

  • Do you have a favorite Drupal module?

I like the Group module. I’ve been using it extensively over the last years and I like how the architecture is designed. It’s also good to know that the maintainer, Kristiaan Van den Eynde, has been working on some core issues to make the module much better. These core issues should also have a larger development impact.

  • What do you expect from Drupal in the future?

There are a few features I’m eager to see added to Drupal. Having Automatic Updates will make it easier for, for example, site builders and smaller organizations to have a secure website. It will definitely decrease the maintenance burden. The Workflow and Layout features will add quite a bit of value to Drupal out-of-the-box, and having the Configuration Management 2.0 roadmap goal delivered would be pretty cool as well.

Furthermore I expect to see more work going towards making Drupal API-first, several huge steps have already been taken which have led to an increase in decoupled Drupal sites. And the Drupal ecosystem will hopefully more and more make use of modern web APIs, like what you see with Progressive Web Apps.

I also hope to see more (standardized) Drupal integrations happening with the Internet of Things. For example Drupal and voice-based services sound pretty cool.

Drupal contributors from our team

Andrew Zahura (shkiper)

  • What do you think is the greatest Drupal benefit?

I think Drupal's main advantage is its community, because it’s the people who support and develop Drupal. They share their work, knowledge, and experience. Thanks to the very large and developed community, Drupal has gained such popularity and has such a large number of modules, features, and themes. Due to the fact that the Drupal community is very open and friendly, anyone can easily find information about a topic of their interest or ask directly on the forum. It is also very easy to promote your ideas and achievements.

  • Do you have a favorite Drupal module?

It is impossible for me to choose only one module, because there are thousands of them and each does an important job. Every year, more modules are added to the Drupal core, which shows that all modules are an important and useful part of the system.

  • What do you expect from Drupal in the future?

Programming, and especially web development, is changing very rapidly. We can see the emergence of new areas of development, frameworks, and libraries. So I expect that Drupal will continue to grow and develop, use the best achievements in other fields, and engage more talented and active people in the community.

Oleh Raban (Zemelia)

  • What do you think is the greatest Drupal benefit?

Its benefits are the community, a relatively easy learning curve, the object-oriented programming approach in Drupal 8, a great selection of tools in the core, and plenty of ready-made contributed solutions.

  • Do you have a favorite Drupal module?

This the Admin Toolbar module. Anyone who works with the Drupal admin dashboard will have tough experiences without this module. So I recommend it to everyone.

  • What do you expect from Drupal in the future?

I would expect the improved UI support for JS libraries out-of-the-box (for example, React). This would mean full-fledged “frameworkness”, if I may say so. But generally Drupal's trends are very cool. It keeps pace with time and with all that multitude of technologies. Perhaps it would even be interesting to see Drupal in some other programming language than PHP. Of course, this sounds unreal, but who knows :)

Ivan Tibezh (tibezh)

  • What do you think is the greatest Drupal benefit?

I think that Drupal’s great benefit is its architecture. Drupal’s architecture (here I mean version 8) is very well thought-out in terms of scalability. You can replace any item with your own one or, in some cases, replace the existing functional elements with your own ones. Of course, Drupal has a foundation that cannot be modified. Still, Drupal is very versatile if compared with other frameworks or CMSs/CMFs.

Even more, due to scalability, Drupal is a versatile system that is not limited to particular tasks (for example, like Magento is only specific to online stores). With this versatility, we can cover a large market. One experienced Drupal developer can easily make business card sites, catalogs, online stores or even social networks based on Drupal. This is also supported by a wealth of Drupal modules for any industry.

  • Do you have a favorite Drupal module?

A simple answer to this question will be “the Views module.” After installing Drupal, every beginner, almost immediately or in the very near future, begins to learn this module. This module can display any information from the database on the website, and it has the flexibility to output anything, in any way.

If you take something "fresher," then it will be the Commerce module for Drupal 8. Everyone knows that the module consists of submodules with a large code. I like Commerce because it gives me inspiration for interesting tasks. There are cases when you need to implement a certain functionality, and something like this already exists in Commerce. So you look into the module and take a similar example, the coding style to solve your task, or just interesting solutions/functions for yourself.

  • What do you expect from Drupal in the future?

I expect, although I'm not quite sure, that Drupal moves in the direction of React. React is a pretty good thing that will make Drupal even faster and, in some cases, more flexible in development. If this happens, it is necessary that everything is implemented well on the backend part (as is the case with Drupal Ajax framework). Here I mean that the vast majority of Drupal developers know PHP and can use jQuery but do not know JS well enough to work with React, and do not even know React itself.

And here is not an expectation but rather a wish. It would be nice to have a built-in Donation system for modules. I am the maintainer of some projects and there is always too little time to deal with then. And if there will be a little incentive system (for customer, a customer needs some feature in the module and can invest, say, $50 into this task) this would be a great system to motivate developers and develop Drupal. A project like this already exists somewhere, but it is specific to the GitHub repository, if my memory does not fail me.

And finally, I expect the 9th version of Drupal :)

Oleksandr Chernyi (BlacKICEUA)

  • What do you think is the greatest Drupal benefit?

In my opinion, Drupal's greatest advantage is its comprehensiveness and extensibility. To me, Drupal, this is primarily a CMF (Content Management Framework), or even rather a pure framework. With custom modules, you can implement virtually any task, from content management to AI applications.

  • Do you have a favorite Drupal module?

I can’t say for sure that I have a favorite module because I'm trying to create new modules — albeit in the context of client projects. The following modules are often used: Paragraphs, Field Group, Selectize.js, Select 2, Chosen, Admin Toolbar, Devel, Configuration Split, Config Ignore, and Config Filter.

  • What do you expect from Drupal in the future?

I am looking forward to switching to Symphony 4 or 5. It works with PHP version higher than 7.1.3, which will lead to the cutting out the outdated methods and functions from the core. I think, this will speed up Drupal.

I also think that there will be a complete transition from hooks to EventSubscribers, which in turn will lead to greater structuring and flexibility when used.

Final thoughts

Hopefully, you also enjoyed reading this blog post with the thoughts of Drupal contributors about Drupal. We would like to emphasize again how valuable they are to us. We wish them all the luck with Drupal development!

With any questions or website ideas, contact our Drupal team.

Jul 09 2019
Jul 09

Why Drupal is the best choice in 2019? Learn from these incredible Drupal 8 case studies

Every day there is a large number of websites that are popping up on the internet. However, some websites stand out more than the others, when it comes to the user experience provided. After seeing this list of awesome Drupal 8 website examples, you will know why Drupal is the best choice to deliver an unforgettable digital experience to your audience.

Part of this selection of awesome websites are our personal selection of favorites from the 2019 Drupal Splash Awards.

1. Chupa Chups

Chupa Chups Drupal

The first awesome Drupal website belongs to Chupa Chups. Chupa Chups had to redesign its website to encompass the vision of “Forever Fun”. On top of that, they had to build a backbone platform that can host all the international Chupa Chups website, which are over 100.

The challenge was to be able to incorporate the needs of their buyer personas in the new website design. In order to do that, they had to make sure that the chosen design was in concordance with them, as well to make sure that it is in line with the different cultural expectations all over the world.

In order to be able to pull the redesign of the website off, Chupa Chups had decided to use Drupal 8. This enables the brand to have a high level of flexibility, while not having to compromise on standardization. By using Drupal 8, Chupa Chups has aimed to centralize the platform, gaining the advantage of easy scalability. The result was a visually stunning website that is in line with the goals that the company has set for the project.

You can read more here.

2. Mintz

Mintz Drupal

Mintz is a general practice, full-service law firm that is employing over 450 attorneys worldwide. The company has noticed that there is a need for a rebranding that can better reflect the hardworking and forward-thinking culture, with which the company guides its clients through times of unprecedented transformation. 

The rebrand was reflected through the launch of a new website that better reflected the culture at Mintz. Among the most notable rebranding changes was the shortening of the name for marketing purposes, as well as a change of the logo. The change received tons of positive feedback from the community as well as the industry.

You can read more here.

3. Panasonic North America

.

Panasonic Drupal

Panasonic is one of the biggest electronics manufacturers in the world. However, the website was no longer reflecting the evolving brand of Panasonic. In other words, the website was not holding up with the times anymore. 

In order to be able to reflect the constantly evolving brand of Panasonic, they had to go for an API first approach. On top of that, they had to put the customer at the center of the project, making sure that the redesign would be in line with customer expectations.

After 18 months of development, the website was finally ready to launch. The API focused approach resulted in the ability to easily integrate other marketing tools. Those tools let the company have better customer data-driven insights. These insights can be used to deliver a better-tailored customer experience.

You can read more here.

4. COIT

Coit Drupal

COIT is a family owned specialty cleaning business that was founded in the year 1945 in California. With over 100 offices throughout the U.S. and Canada, they are serving over 12 million homes. Despite this, their website was really behind the times.

In order to tackle this challenge, a capable CMS had to be chosen. The business had a corporate website with 100+ microsites. Because of the big amount of websites that had to be handled, Drupal 8 was chosen. Drupal 8 allowed COIT to tackle the complexity of the task, while also being able to deliver on the desired visual performance.

The result of this is a brand new website redesign. Geolocation was also added to the website, in order to redirect the customers to the nearest franchise location. Moreover, the new content strategy allows for better-optimized SEO, while also having deeper conversion tracking. These changes have resulted in a better online experience for consumers. 

You can read more here.

5. Rotary Foundation

Rotary Foundation Drupal

The Rotary Foundation is a non-profit organization that is supporting the efforts of Rotary International to achieve world understanding and peace through international humanitarian, educational and cultural exchange programs. The problems started to show when the people that were willing to make donations to the website had to go through a frustratingly long process.

In order to fix this problem, Drupal was chosen. It was chosen because the company already had existing Drupal websites. This made it easier to be able to develop an app that can handle the transactions in a seamless way. On top of that, the app also had to integrate with other internal processes such as finance and membership.

The development of such an app has resulted in positive feedback. It is highly customizable which lets content creators be able to effortlessly deliver their content to the audience. Moreover, donor satisfaction has never been higher. 

You can read more here.

6. WWF Switzerland

WWF Drupal

World Wide Fund is a non-governmental organization that works in wildlife preservation and aims to reduce the human impact on the environment. In order to be able to achieve its goal, WWF decided that they need a strong online presence, basically, a website that can reflect the values that the company stands for. The website has to be able to convince and educate the audience about the impact of human activity on the environment and wildlife. However, in its current state, the website wasn’t able to spark any emotion in its audience, it was like a Wikipedia page.

Part of the challenge was to be able to redesign and incorporate multiple elements at the same time on the new website. One of the requirements that is hard to fulfill was to be able to handle complex editorial, which enabled editors to be able to add pages without having to involve the IT department. On top of that, the website had to have multilingual content, CRM integration, and enhanced analytical capabilities. All these requirements were possible to be med by using Drupal 8.

The of the project was a completely new website design filled with rich content that is able to transmit the emotion through the vibrant pictures and videos of animals. On top of that, the website had become a role model for the other WWF websites around the world, that are now looking to also improve their design.

You can read more here.

7. Arsenal

Arsenal Drupal

Arsenal is one of the biggest football clubs in the Premier League in England. Because f this they have a huge fan base. However, the mobile experience that the club was offering to their fans was really outdated. The club was having two content management systems to separately manage Arsenal.com and it’s sister website. These content management systems were 10 years old and it showed.  

Arsenal recognized the need for a single centralized CMS that is being able to fulfill the needs of the users. Arsenal had selected Drupal 8 for the task. Now, the fans are more engaged than ever with the website that resulted from the change. They started consuming way more content than before, while also giving them easier access to the club fan shops.

You can read more here.

8. The Wildlife Trust

Wildlife Trust Drupal

For 100 years, The Wildlife Trust has been caring for Britain’s wellbeing of the wildlife. It acts as a hub for 46 local trusts by managing local charities, events, and member activities. The challenge arose when the 46 local had to be centralized under a single system.

Because of the scale of the task, Drupal 8 was chosen to resolve this challenge. All of the trusts are operating with a high degree of autonomy. Because of this, Drupal 8 was the perfect platform, it gives enough autonomy, however, it still maintains a level of central oversight. On top of that, Drupal also provides a flexible page layout, a great mobile experience, while also providing language adaptation for Welsh out of the box.

After a year of work on the project, the end result was a seamless online experience with more engaging content that the wildlife conscious audience will surely enjoy more.

You can read more here.

9. Askeladden

Boats Drupal

Askelaaden needed a new website to be able to cater to the needs of its customers. They needed a website that would showcase their products in an aesthetically pleasing way, while also providing a more intuitive customer journey.

For the complexity of the project, they chose Drupal as their CMS of choice. However, Drupal had a steep learning curve and they had a time constraint on their hands. In order to be able to meet the demands without having to change the CMS, they had to find a solution. That’s were Glazed Builder came into play. 

Sooperthemes' visual drag and drop Drupal page builder proved to be the perfect solution for the task. It is a powerful visual drag and drop builder that is based on Drupal. With Glazed Builder Askeladden managed to be able to finish the project in time while also delivering stunning results.

You can have a look at their website here.

10. Coastal Bend Council of Governments

Council Drupal

Coastal Bend Council of Governments was in dire need of a new website design that would be able to communicate their vision and mission in a visual way. 

Drupal seemed like the best option to complete the task. However, the need to complete the task on a short deadline was making the task more difficult. That’s why CBCOG has decided to use Glazed Builder to bring the task to its completion.

The result was a visually stunning website that manages to express the core idea of the council through a visually pleasing experience. Moreover, the Drupal development time was drastically shortened, meaning that the project was delivered on time.

You can have a look at their website here.

Conclusion

There is a reason why Drupal is such a popular and successful CMS. Those websites on the list are proof of the visually stunning capabilities that Drupal can deliver. On top of that, Drupal can also handle complex websites that deliver a multilingual experience to its users. Is Drupal still a good choice in 2019? Definitely.

Jul 09 2019
Jul 09

We’re all about expanding perspectives this week with reads on what comes after infinite scroll dies, how where you live might impact how you interpret data visualizations, and how one organization not only reached a new audience, but monetized it, too. Enjoy!

Brought to you by Kate, Jules, and Natania.

Want to get the next Spark delivered directly to your inbox? Sign up today

(1) Everything you need to know about “fingerprinting.”

What does data privacy look like when cookies aren’t the only entry point for unique identification? Fingerprinting across devices is so accurate that it’s dangerously revealing. Here’s what you can do about it. [The New York Times]

(2) Infinite scroll is dead.

Vacant information overload vs. human-to-human, highly personalized connections: [Is it time to put an end to the Infinite Scroll?](https://www.invisionapp.com/inside-design/kill-infinite-scroll/ (edited) [Invision]

(3) Pride month is every month.

The official Pride Month might be over, but there’s always more to learn. Here are 6 moments in contemporary LGBTQ design history you should know about, plus a guide from the Drupal community pointing to helpful resources for diversity and inclusion. [Invision and Drupal]

(4) Where you live can dictate what you notice.

Want to know how certain data visualizations are received and perceived in rural communities? This great piece, based on an award-winning paper, looks at exactly that. [Visualization Research Explained]

(5) The virtuous circle of digital and IRL.

What happens when you no longer need grocery stores to buy groceries? And how can digital strategy inform the neighborhood grocery store of the future? If you have 15 minutes for this fascinating read, you’re about to find out. [Longreads]

(6) Quick tips on form design.

When it comes to forms, it pays to keep it short. But what if you need more information than just an email address and first and last name? Here are 11 form design guidelines to keep you on the right track. [UX Collective]

(7) More on audience monetization.

When it comes to monetizing audiences—especially those that appear beyond reach—everyone can learn something from the Miami Herald’s approach to its sports-only subscription plan. [Better News]

Get In Touch

Questions? Comments? We want to know! Drop us a line and let’s start talking.

Learn More Get In Touch
Jul 09 2019
Jul 09

Here’s a quick recap of our blog posts from last month. Check it out and revisit your favorite ones!

Interview with Mario Hernandez of Mediacurrent: Contributing to Drupal through workshops and training

We began with another interview in our Drupal Community Interviews series; for this one, we talked with Mario Hernandez, Senior Frontend Developer at Mediacurrent. He was first acquainted with the power of Drupal in 2007 when he was working for the Federal Government.

Even then, during version 6, he was impressed with Drupal’s powerful backend which allowed him to focus on the frontend with which he has more experience. One of his favorite recent developments is the shift from PHP templates to the Twig template engine.

But Mario’s proudest contribution doesn’t have that much to do directly with code - what he enjoys the most is actually providing training and conducting workshops, especially at smaller events where people are very eager to learn. Mediacurrent’s plan is to expand their offerings and start providing custom training that goes beyond just Drupal. 

Read more

Burnout: Symptoms of developer burnout & ways to tackle it

Moving on, we have a somewhat longer blog post that deals with burnout; namely, how to spot the symptoms of burnout when managing a team of developers and what measures to take to prevent burnout from occurring and/or alleviate it when it does occur. 

While burnout is a general problem for workers, it’s especially relevant in the development industry, with higher and higher demands for developers (and from these developers). The first step to preventing it is to be on the lookout for its symptoms, such as lack of energy/motivation, isolation, a decreased quality of work, etc. 

Other preventive measures include a pleasant working environment, enough exercise and motivation, as little overtime as possible and generally a healthy work-life balance. On the individual level, the most important thing is enjoying your work and knowing your limits.

Read more

Interview with Cindy McCourt, Drupal trainer and author

Our second community interview in June featured Cindy McCourt, consultant at IDCM Innovations, Drupal trainer and author. Even when she discovered Drupal in version 4.5, Cindy knew that Drupal was going in the right direction by offering what she calls a data management system rather than a page management system. 

Having managed numerous HTML pages, she knows the importance of code and content reuse, as well as the power of databases and what it takes to integrate websites and databases. Because of Drupal’s powerful capabilities in this area, choosing to work with it was a no-brainer for her.

As a trainer, Cindy emphasizes the importance of good and respectful communication within the Drupal community, pointing out that Drupal is free because a lot of people have dedicated their free time and effort to the project, without necessarily having to. 

Read more

Recap of Acquia's webinar on Content as a Service

The last post we wrote in June was a recap of Acquia’s webinar on content as a service, titled “Shifting from Single Channel to Multichannel Content”. Dries Buytaert and Jake Wilund talked about the challenges of multichannel content and presented Acquia’s upcoming CaaS solution, Content Cloud. 

Since people consume content through different channels across their digital journey, it’s important to produce content that works and is relevant across all these channels. There are three steps crucial to this: standardizing content structures across systems and channels; auditing existing content repositories; and defining the roles and responsibilities involved. 

Some of the features that stood out the most from the Content Cloud demo were API-first, easy inclusion of rich media and easy maintenance of content through multiple systems. If you can’t wait for the official release, you can sign up for beta access here.

Read more

We hope you liked revisiting our content from June. If you don’t want to miss any of our posts, make sure to check our blog every once in a while - we’re sure you’ll find something that interests you!

Jul 09 2019
Jul 09

AmyJune HinelineFrom Nursing to Open Source

It’s difficult to describe the amazing AmyJune Hineline’s impressive three year old Drupal Career without using a slew of adoring adjectives, since she really does embody everything great about Open Source technologies and the communities that support them. 

It’s also difficult to concede that, as much as we’d like to take credit for her remarkable commitment, expertise and all of the goodness and light she brings to Drupal; Drupal Career Online (DCO) was indeed just a well leveraged tool that this very smart, insightful woman chose to help her along her path.

This path and her passion has led her to become the Open Source Community Ambassador for Kanopi Studios. She ensures that the Kanopi team maintains an active connection to the communities it serves, which include Drupal and Wordpress. "...This focus enables others to forge deep community connections that benefit the whole. I help communities discover how they can contribute back in more ways than code," she explains.

Kanopi designs, builds, and supports websites for clients that want to make a positive impact on the world: A great fit for the former hospice nurse and mother of two young adults. Part of her responsibilities also include creating dashboards for data visualization and performing accessibility audits, which also feeds her passion in the accessibility realm. 

AmyJune helps to organizes events, is on the Drupal Core mentoring team and leads first time contributor workshops at regional and local DrupalCamps, and helps mentor attendees in general contribution spaces. It’s an impressive list of responsibilities, especially when you remember she has been at this for just 3 years. 

Her early career route offers no clues as to how she arrived in this auspicious role in Open Source. She began with a college degree she did not use that led her into retail, then a sharp turn into Volkswagen repair. After having children, she rolled into nursing, focusing on hospice, and eventually earned a BS, and later picking up another degree, this one in Human Communication. 

As a hospice nurse, she embraced her role as a guide for patients and families transitioning through the phases of terminal illness, but over time the work took a toll. The unexpected onramp to Drupal came after she did a bit of content entry on a Drupal site. She was intrigued, and decided to become a developer. “My colleague and mentor (loopduplicate) knew of DCO from DrupalEasy podcasts and Mike's (ultimike) presence in the Drupal community.” she recalls.

Coming into the DCO without much technical background, AmyJune had a lot more to learn than most students, which she quickly overcame. Mike recalls she took advantage of every possible resource full force. She worked closely with her mentor, was active in the weekly office hours/co-working labs and was truly engaged in every class session. 

In addition to the classes and lab, she recounts she spent two to three hours a week, perhaps a bit more toward the end, outside of class to get the most of her education.  Within a week after graduating, she was offered a paid internship at Kalamuna which led to her first full time position, and then on to a higher level gig with Hook42

In her current position with Kanopi Studios, AmyJune also helps to organize camps and conventions throughout North America, with a focus on helping communities be more inclusive, as well as playing a mentoring role at events and beyond. These projects help her realize the gratification she drew from nursing. She explains, “...there is a feel good factor that comes when empowering others to get involved in Open Source projects. I love the smiles and reactions when someone I have mentored get theirs first credit or attribution. It feels good to help others feel good.”

As for her thoughts on Drupal Career Online, AmyJune is a big fan of the active and ever growing DrupalEasy Learning Community. "The continued support and mentorship is unbelievable. I love attending the weekly office hours...I like to hear what the other students are working on. Also I enjoy the camaraderie. (and sometimes the commiseration!)" She adds, "The relationships I have forged through the program have been valuable and essential to my growth as a developer."

"The trajectory of my career has been amazing," she reflects. "I started as an intern in programming, moved to a team's community lead, and now being an Open Source Ambassador for Kanopi allows me the time to be a Mentor and Drupal community lead in the camp organizer space…," she explains.  Looking forward, she continues, "I would love to be able to move into a lead mentoring or diplomacy role involving accessibility and inclusion."

AmyJune’s advice to those looking to get into Drupal?   

  1. Find a good mentor. Always ask questions. Never stop asking. Every great Drupaller was once a beginner.

  2. Share what you know. You will always know more than someone else, and when helping others with something you don't know, you can always figure it out together.

  3. Trust in yourself. Imposter Syndrome is a bitch.

As a developer, AmyJune admires patience and humor in the other developers she works with. "Developers who are patient are good collaborators and mentors, and being able to laugh and joke makes the day-to-day work flow so much easier," she explains. 

 You can follow AmyJune at volkswagenchick, on Twitter @volkswagenchick and learn more about some of the Projects is working on: 

A11yTalks- a monthly online meetup dedicated to promoting community discussions on a variety of accessibility issues.  

BADCamp (Bay Area Drupal Camp) - the largest free Drupal Camp in North America.  

WordCamp US  

The next session of Drupal Career Online will be launching new careers beginning August 26th.  If you’d like to learn more about this 12-week certificate program, you can attend one of DrupalEasy’s no-cost Taste of Drupal mini webinars, or visit DrupalEasy’s Drupal Career Online page. You can also contact me at [email protected]


 

Jul 08 2019
Jul 08

Our lead community developer, Alona Oneill, breaks down highlights from Drupal Core Initiative Meetings this past week. You'll find that the meetings, while also providing updates of completed tasks, are also conversations looking for community member involvement. There are many moving pieces as things are getting ramped up for Drupal 9, so if you see something you think you can provide insights on, we encourage you to get involved.

Out of the box initiative meeting (07/02/19)

At this meeting we spoke with the developers at Blackfire.

  • We have a working account with Blackfire to try out Umami,
  • Also tried New Relic - which showed that search indexing is taking a long time,
  • Can we change how Umami installs so that long steps can be skipped to save time?

Issues to work on this week:

Admin UI meeting (07/03/19)

Meetings are for core and contributed project developers as well as people who have integrations and services related to core. 

  • Usually happens every other Wednesday at 2:30pm UTC.
  • Is done over chat.
  • Happens in threads, which you can follow to be notified of new replies even if you don’t comment in the thread. You may also join the meeting later and participate asynchronously!
  • There are roughly 5-10 minutes between topics for those who are multitasking to follow along.
  • the agenda is public and anyone can add new topics *in the document*.

Dialog Issue

  • Dialog style issue.
  • Issues in the core.
  • Proposed the idea that we would try to do research on dialog solutions in Claro and replace jQuery UI dialog with something in our scope of work. An a11y maintainer didn’t like the recommendation and after doing some more research on this it feels like very hard because we might not be able to keep BC at least 100%.

Claro Alpha 4 Goals

Documentation to Work On

  • We should open an issue for tracking our plans for alpha releases, as well as beta and Roadmap.
  • There is supporting documentation for Claro here.
  • Strategic-initiatives needs to be updated.
  • The Proposal to use PostCSS for Claro in core.
  • Design sprint at DrupalCon Europe:
    • Several designers will attend the event, so some would like to have a sprint or focused BoFs.
  • Editor role:
    • We are still missing part of the `Define the new set of permissions` before we can create the patch.
  • Vertical tabs:
    • Mobile design is troublesome, because they are not vertical anymore and behave like the details element. The problem on the design here is that we can't have vertical tabs in small devices, they need to be one  below the other. And we can't have the title above and the content 5 tabs later after all the titles.
Jul 08 2019
Jul 08

Part of my day job is to help tune the Cloudflare WAF for several customers. This blog post helps to summarise some of the default rules I will deploy to every Drupal (7 or 8) site as a base line.

The format of the custom WAF rules in this blog post are YAML format (for humans to read), if you do want to create these rules via the API, then you will need them in JSON format (see the end of this blog post for a sample API command).

Default custom WAF rules

Unfriendly Drupal 7 URLs

I often see bots trying to hit URLs like /?q=node/add and /?q=user/register. This is the default unfriendly URL to hit on Drupal 7 to see if user registration or someone has messed up the permissions table (and you can create content as an anonymous user). Needless to say, these requests are rubbish and add no value to your site, let's block them.

description: 'Drupal 7 Unfriendly URLs (bots)'
action: block
filter:
  expression: '(http.request.uri.query matches "q=user/register") or (http.request.uri.query matches "q=node/add")'

Autodiscover

If your organisation has bought Microsoft Exchange, then likely your site will receive loads of requests (GET and POST) to which is likely to just tie up resources on your application server serving these 404s. I am yet to meet anyone that actually serves back real responses from a Drupal site for Autodiscover URLs. Blocking is a win here.

description: Autodiscover
action: block
filter:
  expression: '(http.request.uri.path matches "/autodiscover\.xml$") or (http.request.uri.path matches "/autodiscover\.src/")'

Wordpress

Seeing as Wordpress has a huge market share (34% of all websites) a lot of Drupal sites get caught up in the mindless (and endless) crawling. These rules will effectively remove all of this traffic from your site.

description: 'Wordpress PHP scripts'
action: block
filter:
  expression: '(http.request.uri.path matches "/wp-.*\.php$")'
description: 'Wordpress common folders (excluding content)'
action: block
filter:
  expression: '(http.request.uri.path matches "/wp-(admin|includes|json)/")'

I separate wp-content into it's own rule as you may want to disable this rule if you are migrating from a old Wordpress site (and want to put in place redirects for instance).

description: 'Wordpress content folder'
action: block
filter:
  expression: '(http.request.uri.path matches "/wp-content/")'

SQLi

I have seen several instanced in the past where obvious SQLi was being attempted and the default WAF rules by Cloudflare were not intercepting them. This custom WAF rule is an attempt to fill in this gap.

description: 'SQLi in URL'
action: block
filter:
  expression: '(http.request.uri.path contains "select unhex") or (http.request.uri.path contains "select name_const") or (http.request.uri.path contains "unhex(hex(version()))") or (http.request.uri.path contains "union select") or (http.request.uri.path contains "select concat")'

Drupal 8 install script

Drupal 8's default install script will expose your major, minor and patch version of Drupal you are running. This is bad for a lot of reasons.

Drupal 8's default install screen exposes far too much information

It is better to just remove these requests from your Drupal site altogether. Note, this is not a replacement for upgrading Drupal, it is just to make fingerprinting a little harder.

description: 'Install script'
action: block
filter:
  expression: '(http.request.uri.path eq "/core/install.php")'

Microsoft Office and Skype for Business

Microsoft sure is good at making lots of products that attempt to DoS its own customers websites. These requests are always POST requests, often to your homepage, and you require partial string matching to match the user agent, as it changes with the version of Office/Skype you are running.

In large organisation, I have seen the number of requests here number in the hundreds of thousands per day.

description: 'Microsoft Office/Skype for Business POST requests'
action: block
filter:
  expression: '(http.request.method eq "POST") and (http.user_agent matches "Microsoft Office" or http.user_agent matches "Skype for Business")'

Microsoft ActiveSync

Yet another Microsoft product that you don't why it is trying to hit another magic endpoint that doesn't exist.

description: 'Microsoft Active Sync'
action: block
filter:
  expression: '(http.request.uri.path eq "/Microsoft-Server-ActiveSync")'

Using the Cloudflare API to import custom WAF rules

It can be a pain to have to manually point and click a few hundred times per zone to import the above rules. Instead you would be better off to use the API. Here is a sample cURL command you can use do import all of the above rules in one easy go.

You will need to replace the redacted sections with your details.

curl 'https://api.cloudflare.com/client/v4/zones/XXXXXXXXXXXXXX/firewall/rules' \
  -H 'X-Auth-Email: XXXXXXXXXXXXXX' \
  -H 'X-Auth-Key: XXXXXXXXXXXXXX'
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json'
  -H 'Accept-Encoding: gzip'
  -X POST \
  -d '[{"ref":"","description":"Autodiscover","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path matches \"\/autodiscover\\.xml$\") or (http.request.uri.path matches \"\/autodiscover\\.src\/\")"}},{"ref":"","description":"Drupal 7 Unfriendly URLs (bots)","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.query matches \"q=user\/register\") or (http.request.uri.query matches \"q=node\/add\")"}},{"ref":"","description":"Install script","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path eq \"\/core\/install.php\")"}},{"ref":"","description":"Microsoft Active Sync","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path eq \"\/Microsoft-Server-ActiveSync\")"}},{"ref":"","description":"Microsoft Office\/Skype for Business POST requests","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.method eq \"POST\") and (http.user_agent matches \"Microsoft Office\" or http.user_agent matches \"Skype for Business\")"}},{"ref":"","description":"SQLi in URL","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path contains \"select unhex\") or (http.request.uri.path contains \"select name_const\") or (http.request.uri.path contains \"unhex(hex(version()))\") or (http.request.uri.path contains \"union select\") or (http.request.uri.path contains \"select concat\")"}},{"ref":"","description":"Wordpress common folders (excluding content)","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path matches \"\/wp-(admin|includes|json)\/\")"}},{"ref":"","description":"Wordpress content folder","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path matches \"\/wp-content\/\")"}},{"ref":"","description":"Wordpress PHP scripts","paused":false,"action":"block","priority":null,"filter":{"expression":"(http.request.uri.path matches \"\/wp-.*\\.php$\")"}}]'

How do you know the above rules are working

Visit the firewall overview tab in Cloudflare's UI to see how many requests are being intercepted by the above rules.

Cloudflare's firewall overview screen showing the custom WAF rules in action

Final thoughts

The above custom WAF rules are likely not the only custom WAF rules you will need for any given Drupal site, but it should at least be a good start. Let me know in the comments if you have any custom WAF rules that you always deploy. I would be keen to update this blog post with additional rules from the community.

This is likely the first post in a series of blog posts on customising Cloudflare to suit your Drupal site. If you want to stay up to date - subscribe to the RSS feed, sign up for email updates, or follow us on Twitter.

Jul 08 2019
Jul 08

For the past three years, developers, IT, and marketing professionals have gathered in NYC for “Decoupled Days, a growing but impactful event with influential speakers and change agents from across the tech space, to share and learn about decoupled architecture solutions for some of the world’s leading brands and organizations.

While the topic of decoupled architecture solutions may seem hyper-specific for a two-day conference, there is an aggressively (growing) interest and investment in decoupled architecture strategies across industries, all to enable the digital brand experiences they require to stay competitive.

Decoupling the front end of an organization’s platform from their back end allows for more flexible design capabilities and the ability to update the design much faster at the speed that marketing teams need to move. When the back end of your website is decoupled, you can easily integrate and swap micro-services in and out to provide the latest and most useful tools and functionality without a complete site redesign.  

Here at Phase2, we work with many of our enterprise clients on decoupling their digital architectures to meet their brand experience goals. We’re thrilled to participate in the organization, sponsorship, and thought leadership of this event. If you plan to attend this year’s event, (and we think you should!), be sure to check out some of Phase2’s front-end leaders as they share best practices and cutting-edge tooling in the following sessions:

We hope you’ll join us July 17th-18th in NYC to learn more about business, technology, and diversity when it comes to decoupled architectures for seamless omnichannel brand experiences that inspire audiences.

Jul 08 2019
Jul 08

Having worked the last five years as a Drupal freelancer, getting involved in the Drupal Community as both a Sprint Mentor and member of the Drupal Community Working Group, Rachel has now moved to dedicate all of her time as the Drupal Association’s new Community Liaison.

Jul 07 2019
Jul 07
ReactPHP code

ReactPHP is an event-driven non-blocking PHP framework that allows to you work in a long-running script through an event loop. At its core, ReactPHP provides an event loop and utilities to trigger events at specific intervals and run your code. This is different than normal PHP script execution which of a short lifecycle and per individual requests. 

ReactPHP has been used to build web server applications, web socket servers and more. But, what if we used ReactPHP to execute operations and tasks on a Drupal application?

Technically this could be feasible with a set of cron jobs scheduled at specific intervals which invoke Drush or Drupal Console commands. But there is a limitation there: The ability to manipulate cron jobs entries for the user whenever a deployment occurs. Hosting providers like Platform.sh support this, but only on the main application container. Worker containers do not support cron job definitions. Also, what about handling errors?

We can combine the ReactPHP event loop with the ReactPHP ChildProcess library to run our command line tools. The child process attaches to the event loop and allows us to stream output from STDOUT and STDERR. This allows us to log output from the command or handle errors which occur during these background processes.

It is easiest to create a function that executes a new child process, provides an event loop for it, and binds events to the output streams.  

function run_command(string $command): void {
  $loop = React\EventLoop\Factory::create();
  $process = new React\ChildProcess\Process($command);
  $process->start($loop);
  $process->on('exit', function ($exitCode) use ($command) {
    // Trigger alerts that the command finished.
  });
  $process->stdout->on('data', function ($chunk) {
    // Optinally log the output.
  });
  $process->stdout->on('error', function (Exception $e) use ($command) {
    // Log an error.
  });
  $process->stderr->on('data', function ($chunk) use ($command) {
    if (!empty(trim($chunk))) {
      // Log output from stderr
    }
  });
  $process->stderr->on('error', function (Exception $e) use ($command) {
    // Log an error.
  });
  $loop->run();
}

I am a big fan of Rollbar and have logs sent there.

Now, let's create our main event loop which will run our commands at different intervals. We can run cron every twenty minutes

$loop = React\EventLoop\Factory::create();
// Run cron every twenty minutes.
$loop->addPeriodicTimer(1200, function () {
  run_command('drush cron');
});
$loop->run();

If you're using a queuing system to process jobs asynchronously via the Advanced queue module, you may want a more continuous processing that acts as a daemon.


$loop = React\EventLoop\Factory::create();
// Every thirty seconds, process jobs from queue1
$loop->addPeriodicTimer(30, function () {
  run_command(sprintf('drush advancedqueue:queue:process queue1'));
});
// Every two minutes, process jobs from queue2
$loop->addPeriodicTimer(120, function () {
  run_command(sprintf('drush advancedqueue:queue:process queue2'));
});
$loop->run();

This has allowed us to run Drush as a child process in a ReactPHP event loop to run tasks. What if we actually bootstrapped Drupal and invoked our code directly instead of through child processes? We can!

To start, we need to bootstrap Drupal. This requires the creation of a request object and a mocked route. The DrupalKernel and other components are coupled to the request containing some meta information about a route. Luckily, Drupal supports a <none> route.

We require the autoloader and create our request object. I usually have my PHP scripts in a scripts directory at my project root, so my autoloader is in ../vendor/autoload.php.

$autoloader = require __DIR__ . '/../vendor/autoload.php';

$request = Symfony\Component\HttpFoundation\Request::createFromGlobals();
$request->attributes->set(
    Symfony\Cmf\Component\Routing\RouteObjectInterface::ROUTE_OBJECT,
    new Symfony\Component\Routing\Route('<none>')
);
$request->attributes->set(
    Symfony\Cmf\Component\Routing\RouteObjectInterface::ROUTE_NAME,
     '<none>'
);

Next, we bootstrap the DrupalKernel. We need to run the bootEnvironment method, this sets up some required information for Drupal. Next, we need to specify the site path which contains the settings.php we want to use; generally, it is sites/default. Then we just boot the kernel and run the pre-handle of the request to get everything up and running.

$kernel = new Drupal\Core\DrupalKernel('prod', $autoloader);
$kernel::bootEnvironment();
$kernel->setSitePath('sites/default');
Drupal\Core\Site\Settings::initialize($kernel->getAppRoot(), $kernel->getSitePath(), $autoloader);
$kernel->boot();
$kernel->preHandle($request);

Now we can have our event loop tick away and execute our code as needed.

$loop = React\EventLoop\Factory::create();
$loop->addPeriodicTimer(10, function () {
    $cron = \Drupal::service('cron');
    $cron->run();
  });
$loop->run();

Here is a link to a Github gist of the complete files exampled here: https://gist.github.com/mglaman/6f5b0b2194d2f5ec7f1a40d00dd5ca6c

Jul 05 2019
Jul 05

"The digital voice assistant market is projected to experience continued expansion in the coming years, with number of voice assistants in use increasing from 3.25 billion in 2019 to around 8 billion by 2023" - Statistia

“Read out the headlines on the front page of today’s edition of The New York Times newspaper”. Say something like this to Google Home or Amazon Echo and you will get to listen to a voice reading out the news. Forget swiping, scrolling and typing, just talk to a voice assistant and hear what you want. Voice interfaces are all the rage in recent times.

A pile of books, a voice interface device, a pen and an apple kept close to each other


Not only is it helpful for your personal use, but organisations from different industries can find it meritorious. When it comes to new publishing opportunities, voice interfaces are right up there alongside artificial intelligence, augmented reality and blockchain. This world is not a part of a fairy tale and voice interface do pose a few challenges. Before we see how publishing companies make a great use of voice assistants, let’s explore voice interfaces a bit.

What exactly are voice interfaces?

Voice user interfaces (VUIs) enable the user to communicate with a system through voice or speech commands. Amazon Alexa, Echo dot, Google Home, Google Mini, Siri, Cortana and the Google Assistant some of the great examples of VUI.  The primary advantage of a VUI is that it enables you to interact with a product hands-free, eyes-free.

The primary advantage of a VUI is that it enables you to interact with a product hands-free, eyes-free.

Applying the same design guidelines to VUIs as to Graphical User Interfaces (GUI) is impossible. There are no visual affordances in a VUI. That means when you are looking at a GUI, you have no apparent indications of what the interface can do or what are the options available. When designing VUI actions, it is of paramount significance that the system clearly lays down possible interaction options, lets the user know what functionality is he/she is using and limit the amount of information to an amount that the user can remember.

Now, why are they important? It’s growing at an alarming pace and Gartner, a research firm, says that it is a trend, no discussion. You can see ‘Virtual Assistant’ in the graphical representation of emerging technologies below.

raphical representation showing parabolic line and blue dots and yellow triangles on it to show the Gartner's hype cycle for emerging technologiesSource: Gartner

VUI is getting better and better. In just an year, the betterment is apparently visible. Whether it is Google Home or Siri, advancements are impeccable as can be seen in the following graph.

Bar graph showing a light and dark green vertical bars to depict the improvement in voice assistants

Things that publishers need to know

There is a land grab to own skills and in the arena of VUI, skills can be split into two categories.

First is the branded skills that are connected to your brand and could not be owned by any other organisation. Skills like TED’s ‘play the latest TED Talk’ action and the Wall Street Journal’s ‘What’s News?’ come into this category.

Another category is the one that encompasses more generic skills like “Alexa, give me the headlines on sports” or “Okay Google, give me the stock market news”. Ownership of such generic skills would give you the sole authority over all the categories from the creation of first-mover advantage in the market as brands race to the capturing skills before they are gone.

This can make things tougher for brands who are looking to extract market-specific skills in both the generic and branded categories. And like most things, it is all about finding the right target.

Consumer Intelligence Research Partners stated in a study that Amazon Echo customer spend 66% more than average Amazon customers. This goes to say that Amazon can now afford to sell Echo devices at a lesser price than originally planned. They can even occasionally take a loss on devices for gaining a greater share of consumer spending. The inference that we get from this for the publishers is that optimising for voice search could result in a revenue boost.

Benefits of voice assistants for publishers

Emphasising on Customer Experience

Fabrice Rousseau, Amazon’s general manager of Alexa skills, emphasised on reinventing customer experience with the help of voice technology in his keynote address at the CMO Digital Insight Summit. He said, “When we moved from desktop to mobile we didn’t bring the desktop experience to mobile, we invented a very specific mobile experience”. He further stated, “When you move from mobile to voice don’t bring your mobile experience. Just invent an experience that is unique to voice.”

Fabrice Rousseau, Amazon’s general manager of Alexa skills, standing on the stage and several people sitting and listening to him.

One of the greatest examples of the importance of customer experience through voice technology can be seen through Amazon Audible. If you are a fan of audiobooks, the odds are that Amazon is your preferred place to shop. Of all the ways Amazon has been able to prove its hegemony in the book market, its share of audiobook sales probably represents its most formidable dominance.

Branding with skills

It is of utmost importance to note that, as far as most of the publishers are concerned, although the VUIs have been storming the market, there’s still plenitude of advancements in the pipeline. In spite of early triumphs with branded skills and flash briefings, VUIs still operate at a fairly low level such as following the commands to play music or read out your appointment dates. With that being said, many publishers are already working on plans for expansion. With the land grab to own skills still underway, the ones who make the first move will taste the success in the future.

What are the major challenges?

Dearth of personality

Voice assistants’ dearth of personality is one of the foremost concerns of publishers. Chris Gathercole, the head of FTLabs at the Financial Times, and his team used Amazon Polly for converting existing text articles into audio that is then delivered by ‘Artificial Amy’. What they observed was that ‘Amy’ was quick to learn and was also cost-effective but her lack of human-like characteristics was irksome and killed the humour or nuance of a piece.

Banal and disturbing

Automated voices are often either of banal nature or straight up disturbing which can put users off. An amalgamation of artificial and human voices could temper the issue with a voice actor reading parts of the text and a computerised voice contributing further snippets.

Automated voices are often either of banal nature or straight up disturbing

Privacy concerns

There are privacy concerns hovering around the ownership of devices that are essentially perpetually eavesdropping on your home. Consumer Watchdog, a customer advocacy group, stated in a study. “These patents show that smart devices target moments in between screen time to monitor sleep habits, listen in on dinner conversations, and track when users shower. Access to this data can flesh out Google and Amazon’s profiles of their users in order to help them more accurately server targeted ads”.

Conclusion

Conversations will evolve into an integral element of digital experiences. Interfaces that enable people to use natural language - from chatbots based on typing and reading to voice interfaces that are based on speaking and listening - are highly popular but also very immature.

However, with more devices without screens being connected, more consumers will look to voice for controlling their efforts and to perform more intricate tasks. Enterprises including publishing companies need guidance from Customer Experience (CX) pros so that their efforts at building conversational interfaces help customers instead of driving them away.

Looking for CX pro? Look no further than OpenSense Labs as we strongly believe in offering a wonderful digital experience through a suite of services.

Contact us at [email protected] to know more about the benefits of voice interface for a publishing company.

This block is broken or missing. You may be missing content or you might need to enable the original module.

Jul 05 2019
Jul 05

Just like every month, we’ve been reading a lot of interesting content related to Drupal and have prepared a short selection of our favorite Drupal-related posts from June. It wasn’t exactly a straightforward task, what with so many quality blog posts, but we’ve managed to narrow it down to the following list. We hope you enjoy the read!

Promote Drupal Status Update

The first post on June’s list is an update on the status of the Promote Drupal Initiative from the Drupal Association’s blog, written by Tim Lehnen who has just finished with his role as the interim executive director of the Association in June. 

The post begins with the conception of the initiative, as well as its purpose, which is to provide decision-makers with helpful material for the adoption of Drupal. Then, Tim provides an update on the progress of the first two phases of Promote Drupal which are well on their way to completion. 

Finally, he outlines some next steps of the initiative and finishes the post with a CTA inviting individuals and agencies to dedicate some of their time to participating in the initiative and promoting Drupal.

Read more

Adventures with Drupal's Layout Builder

The next post that stood out to us is Fuse Interactive’s Adventures with Drupal’s Layout Builder. The Layout Builder had been, until the recent 8.7 release, an experimental module that entered the Drupalverse in version 8.5. Now that it’s a part of Drupal’s core, it makes sense to start using it as much as we can to discover all its capabilities. 

In this post, Niall Morgan from the Fuse Interactive team relates their experience with using the module and provides some guidance for setting it up, even including a section on creating your own layout templates. He concludes the post with some points for further discussion, e.g. custom styling to blocks and sections via config options and utility classes.

Read more

Boost your speed with lazy images

Another post that caught our attention was one by James Williams of ComputerMinds on lazy loading images. With such a high pressure on websites to load everything super fast, it’s become crucial to optimize our images for our websites and web applications.

A really efficient way of doing this is making images load lazily. That means that they’re only loaded when the image is scrolled up into the user’s view. This is achieved by first using the data-src html attribute instead of the regular src, then loading the image with JavaScript when it’s observed as being in the view. 

James provides the code for setting up an intersection observer in Drupal, as well as some tips for further customization, such as including placeholder images.

Read more

The distributed CMS: How the decoupled CMS endgame will impact your organization

While not exactly a Drupal-specific post, this next one has such important implications for the future of content management systems in general that we felt it definitely deserves a mention. It was written by Preston So and discusses the fourth wave of content management systems - the distributed CMS.

He begins with some basics concerning the current channel explosion and a brief overview of modern web development, then goes on to explain the decoupled CMS and outlines three reasons for its widespread popularity: pipelined development, interchangeable presentation layers and API convergence. 

Finally, he describes the emerging distributed CMS, or content mesh, in which the presentation layer itself as well as the services within this presentation layer are both interchangeable. A great example of a technology which enables this is Gatsby.

Read more

An Overview for Migrating Drupal Sites to 8

As its title already suggests, the subject of this post written by Lullabot’s Juampy NR is migration to Drupal 8 from previous versions of Drupal (namely, D7 in the examples given by Juampy). 

The post first explains migration files and the different approaches to migrating configuration and content. Migrations can be done in two ways: either by automatically generating migrations with the Migrate Upgrade module or by writing them by hand, which is the better choice when the content model undergoes significant changes. 

All in all, Juampy’s post provides all the basics you need to know when migrating your existing Drupal site to Drupal 8. The Migrate Upgrade module really simplifies this process, so he advises to make use of it even when writing migrations manually. 

Read more

Announcing a private beta of Acquia Content Cloud

Moving on with our list, we have a blog post by Dries announcing Acquia’s new content-as-a-service solution called Acquia Content Cloud. It’s an invaluable resource for marketers and content editors to effortlessly create content than can be reused and published across numerous channels. 

Content Cloud is especially handy for larger organizations with a large number of sites or applications and content creators. It allows for easy governance of these content creators and easy synchronization of content across channels. 

This new product was unveiled at the Acquia Engage conference in London and is currently in beta phase; you can get a taste of it by watching the demo video included in Dries’ post and/or signing up here for the private beta.

Read more

Looking good Drupal, looking good!

Drupal’s authoring experience used to be quite lacking, especially when compared with a CMS such as WordPress where the authoring experience is really intuitive. This changed, however, with the arrival of Drupal 8. 

In this post, Glenn Hodgkinson of Thinkbean looks at the three main areas of the improved AX in Drupal 8: the Gutenberg editor adopted from WordPress, the Layout Builder which has just recently become a part of core, and better management of media entities. 

Thanks to these newly introduced features, content creators now have a lot more control over their content and don’t need to rely so heavily on developers, which brings Drupal’s authoring capabilities on par with its technical capabilities. 

Read more

The Myth of Inaccessible React

Finally, we have a post by Mediacurrent’s Ben Robertson in which he dispels the myth of React having very poor accessibility. It’s a common misconception that JavaScript libraries have accessibility issues and, with React being one of the most popular ones, it often takes the blame. 

However, this is not the case in Ben’s experience. In his blog post, he explains how developers can use the accessibility tools available to React to greatly diminish the number of accessibility errors in their code. Specifically, he takes a look at linting tools, the react-axe library and Storybook. 

If you just want to see first-hand how things work or need to set up a project quickly, Ben also provides a Gatsby starter with all these tools already built in.

Read more

This concludes our list of the top Drupal posts from June. If you enjoyed it, feel free to visit our blog and check out our other posts!
 

Jul 04 2019
Jul 04

If you want the visitors to settle down on your website and register, you definitely need a special tool to make both the registration and login processes easier and faster. Luckily, Drupal 8 possess a number of benefits, and modules for social login is one of them!

The team at InternetDevels has prepared a list of top Drupal 8 modules for social login functionality. Stay tuned!

The best Drupal 8 social login modules

Check out this list of modules for social login in Drupal 8 and choose the one that suits you best!

  • OneAll Social Login

OneAll Social Login is a powerful module that will let your users register on the website from their accounts in 35+ social networks, such as Google, Facebook, Twitter, and more. The great benefit of this module is that it is fully compliant with all European and U.S. data protection laws. With the help of OneAll Social Login, you can easily increase the user registration rate because the registration process is much more simplified.

  • Social Auth

The Social Auth module is part of the Social API. It does not only help users login effortlessly but also lets website owners get data from a provider, and much more. An important aspect of the new 2.x version is that it possesses its own content entity, which means that all data can be stored in the database. Visitors can register on the website through 30 social networks with the help of this Drupal 8 social login module, including Slack, Reddit, Uber, and more.   

  • Auth0 Single Sign On

Auth0 Single Sign On replaces standard Drupal 8 login forms with one powered by Auth0. This social media module implements authentification with multiple platforms, such as GitHub, Twitter, Facebook.

Auth0 Single Sign On Drupal module

  • Social Auth Google

The Social Auth Google module allows users to register and login to the website with the help of Google account. This Drupal 8 social login module allows sites to request any scopes so that any tasks requiring authentication with Google services can be performed.

Social Auth Google Drupal module

  • HybridAuth Social Login for Drupal 7

HybridAuth Social Login integrates into Drupal with the help of HybridAuth library and allows your visitors to login and register using Facebook, Twitter, Windows Live, Instagram, AOL, and much more. The greatest advantage of this module is that it doesn’t depend on any external service and doesn’t load any external CSS or JS files. It can also connect a few social identities to one account and log in users through any of them.

Choose your perfect Drupal module for social login

Now you know what to pay attention to when choosing a module for social login in Drupal 8. And the team of Drupal experts at InternetDevels is always at hand to assist you with modules installation and configuration.

If you didn’t find the module that suits you, we could easily create a custom one that would meet all your requirements! Do not hesitate to contact us 24/7 if you need any help or have questions regarding Drupal 8 modules for social login.

Jul 04 2019
Jul 04

Developing a website for a higher education institution may be tough, as universities have plenty of departments and branches. Despite the fact that each department has its own site with specific content, all of them have to function under the same CMS and be closely connected. How do you know which CMS is right for your university website? Let’s sort things out!

Drupal vs WordPress for higher education institutions

The most popular choices for higher education institutions websites are Drupal and WordPress. However, WP lacks functionality, security, and accessibility necessary for a complicated higher education institution platform.

Did you know that 71 out of the top 100 universities, including Harvard University, University of Oxford, and Yale, use Drupal for their websites? It’s not surprising if you are familiar with all of Drupal benefits.

Today, the team at Drudesk explores the benefits of Drupal for university website development.

Drupal’s benefits for university websites

Drupal offers a bunch of tools and features necessary for a complicated university website development. Here are the main ones:

  • Accessibility

Caring about accessibility for users with physical disabilities is a must. Drupal 8 possess a number of features that support website accessibility standards. They help screen readers understand web pages, add alt text for images, take care of fonts and colors, and much more.

Note that you can always contact Drudesk for a website accessibility audit to see if your website is optimized for people with impairments.

  • Information security

University websites contain a lot of valuable content that should be kept safe. Luckily, Drupal is one of the most secure CMS, as it offers regular core, modules, and security updates. With Drupal you can be sure that your platform maintains the highest level of security.

  • User roles and permissions

University websites are visited by professors, students, administration staff, and much more. All of them need different permissions for creating and editing website content based on their roles at the university. Drupal offers out-of-the-box user roles, as well as a number of contributed user access modules that will help you easily configure roles and permissions on the site.

  • Multilingual functionality

Drupal 8 possess a multilingual feature out-of-the-box. This is extremely useful for higher education institutions, as students all over the globe will access the website. Drupal translates all information available, from content to interface, and offers a choice of 100+ languages to install on websites.

  • A multisite approach

Multisiting is usual for higher education institutions, as they have different departments that require sister domains. Things become easy with the Drupal multisite feature that lets you have as many websites as you need on the same Drupal installation. It provides unlimited opportunities for sharing content, managing the settings, and giving access between multiple sites.

  • Easy content creation and editing

Higher education websites update and add content regularly. Drupal 8 is a solution for content creators, as it possesses a number of built-in features for easy content creation, from posting to editing.

  • Hundreds of themes and templates

Drupal offers various design templates that are pretty much effortless to use while ensuring consistency across an entire institution.

Great examples of higher education websites built in Drupal

Harvard University

Harvard university website on Drupal

Rutgers University

Rutgers University website on Drupal

Stanford Graduate School of Business

Stanford Graduate School of Business website on Drupal

University of Oxford

University of Oxford website on Drupal

University of Colorado 

University of Colorado website on Drupal

Develop a website for a higher education institution on Drupal!

Take a look at the Maryland Global University, a website created by our web development partners: InternetDevels agency. It is supplied by the eCommerce functionality for buying online courses, as well as Moodle integration — a well-known LMS (learning management system).

Maryland Global University website on Drupal by InternetDevels

Don’t hesitate over the choice of CMS for university website development anymore — Drupal is definitely the solution! Drop us a line regarding your project and we’ll immediately get back to you to discuss all the details of the project.

Pages

About Drupal Sun

Drupal Sun is an Evolving Web project. It allows you to:

  • Do full-text search on all the articles in Drupal Planet (thanks to Apache Solr)
  • Facet based on tags, author, or feed
  • Flip through articles quickly (with j/k or arrow keys) to find what you're interested in
  • View the entire article text inline, or in the context of the site where it was created

See the blog post at Evolving Web

Evolving Web