Mar 27 2019
Mar 27

We’re excited to attend and present at DrupalCon Seattle this year. Here’s a breakdown of what we’re looking forward to day by day, and information about where you can see Amazee sessions throughout the week.

Monday, 8 April

Monday and Tuesday will be a time for summits, sprints, and BoFs. Be sure to check out Michael Schmid as part of the Performance and Scaling Summit. In the evening you can join the DrupalCon Monday Night Pub-Crawl for community and drinks.

Tuesday, 9 April

In addition to the many summits and sprints be sure to check out the First-time Attendee Networking Breakfast if you're new to DrupalCon. After hours you can join a group run or one of several parties.

Wednesday, 10 April

In the morning, don’t miss the annual DriesNote where you can hear about the current state of Drupal as well as what the future holds. In the evening, the prestigious Splash Awards will showcase the best of Drupal from 2018 in the inaugural global international edition of these awards.

Thursday, 11 April

Thursday will be a day full of Amazee sessions. First up, Maria Comas will host her session GraphQL 101: What, Why, How from 09:45 - 10:15 in Room: 606. Be sure to check it out to get a basic overview of GraphQL and how to get started using it.

Catch John Albin Wilkins and his session CSS-in-JS and Drupal sitting in a tree… from 10:45 - 11:15 in Room: 6B. John will discuss the learnings from Amazee Labs trying several different CSS-in-JS solutions and why we finally decided on using CSS Modules.

In the afternoon, Michael Schmid will present Best Practices: How We Run Decoupled Websites with 110 Million Hits per Month at 13:00 in Room: 6C.

Finally, you can finish out Thursday with the popular social event Trivia Night where you can test out your Drupal knowledge with a chance to win prizes or earn the title of Drupal trivia champions, and win small prizes to boot!

Friday, 12 April

On the final day of DrupalCon, the community comes together to make contributions before saying goodbye until next year. We can’t wait to see all of you at DrupalCon 2019!

Mar 27 2019
Mar 27

Subscribe to the TCDrupal News

*/
Mar 27 2019
Mar 27

A handful of “life-saving” module releases, enlightening tutorials, well-curated  Drupal theme selections... This month has “spoiled” us with lots of valuable Drupal blog posts. Therefore, coming up with a shortlist of 5 Drupal blog posts has been quite a challenge for us here, at OPTASY.

But, in the end, we did manage to trim our bulky lists of favorites. To focus on our common preferences and keep only the following truly valuable pieces of content on Drupal in our final selection:
 

Since keeping consistency across the websites that we develop is an ever-present challenge and priority for us, this post on building pattern libraries in Drupal came in handy...

While reading it we were already:
 

  • counting just how much time we would save for creating new functionalities and setting up new pages
  • anticipating how easy it would be to maintain our future Drupal websites once we've integrated pattern libraries that anyone could tap into and streamline the creation of new features
  • imagining how convenient it would be to just reuse design elements and functionality stored in those libraries
     

Overall: we couldn't stop thinking how streamlined the whole Drupal development process would be, for all our future projects. And to what extent the end user's experience would get improved by means of... consistency.

The solution the OpsenSense Labs presents there is an effective formula: Pattern Lab + Drupal 8= Emulsify.

Then, they get into details on:
 

  • what Emulsify is: a prototyping tool leveraging atomic design that you could rely on for setting up a living style guide
  • how Emulsify works: by integrating Pattern Lab it enables you to easily put together and manage components and thus streamline your entire development process in Drupal 8
     

The team from InternetDevels have surprised us with a present in the form of a new module that has the potential to become the newest tool in our Drupal development “essential toolkit”.

One including other valuable performance optimization Drupal modules...

It's called Quicklink and here's what makes it so... “tempting”: it uses link prefetching to boost up page loading time on Drupal 8 websites.

Take this example take from their blog post: a visitor lands on a specific page on your website with the intention of accessing other links as well. Once the used browser goes idle, the module tracks down his/her viewports and caches the content corresponding to the links in that viewport.

Once he/she clicks on any of those links, the content will have already been safely stored in the cache and thus it gets displayed much quicker. That is what link prefetching is all about...

Next, the blog post's author goes on delivering details on the underlying library, the API and method this module uses for link detection and respectively waiting for the browser to go idle. Then, it gets into specific details on how to install and configure the module.
 

Why have we included Vardot's piece of content on our favorite Drupal blog posts list: March edition? 

Because versatility has been one of their key criteria when selecting those specific 7 themes. They anticipated website owners' and development teams' requirements in terms of customization and flexibility — not just look & style — when picking their Drupal themes.

In this respect, their collection included Drupal themes ranging from Progressive to Winnex, from OWL to... Edmix.
 

Dries' post is a long-time awaited news: Drupal now ships with JSON:API support.

According to his predictions, in just a few months all Drupal 8 websites will get support for this module.

What does this mean?
 

  • it means that the once far-to-reach future where Drupal would be API-first is now... closer than ever 
  • Drupal teams get empowered to create content models with no coding required, straight in the Drupal UI
  • we're being provided with a web service API that pulls that content into JS apps, voice assistants, chatbots...
     

Just imagine: with this module in core, all your comments, blog posts, tags, and other Drupal entities will get easily accessed via JSON:API web service API. This way, you can serve your content across an entire ecosystem of platforms and devices...
 

We ran over this article the other day and we know just had to add it to our top 5 favorite Drupal blog posts of the month.

It presents a solution to a too frequent challenge: handling those scenarios where you're not 100% happy with the search results provided by Search API Solr and you need to... tweak them. 

To tailor them to your specific needs, so that they're fully relevant for your end users...

Now you have the option to trigger the Drupal module Search Overrides' power. It's designed to enable website admins to override the generated search results. Manually...

Say you're one of these Drupal site admins: you choose the nodes to be placed at the top of the search results generated when entering specific search terms and remove those nodes that shouldn't get displayed. As easy as that! The module will provide you with a method to leverage whenever you need to override search results on a Drupal website.

Note: the Echidna team's now working on integrating functionality that would allow for search result overrides to be... role-specific. For instance, a Drupal back-end team would get different results compared to the end users, for the very same search term.


The END!

These pieces of content have been our top favorite Drupal blog posts this month. How about yours?

Photo by Franck V. on Unsplash

Mar 27 2019
Mar 27

The biggest reason why customers are leaving is usually the fact that they have received an unsatisfactory service or product from the company. Nowadays, consumers are quick to penalize a company for an unsatisfactory experience. On top of that they are well aware that their influence in the marketplace is stronger than ever, are willing to use that power to influence your companies reputation for both good or ill. The leading causes for customers leaving is that the company or brand is not taking into consideration the customer needs. On top of that, providing a poor customer support and not learning from the feedback also adds up to the customers leaving. Naturally, not every customer experience can be a positive one, at some point there are bound to be some mistakes, maybe a parcel is delivered on the wrong address or the product delivered is in poor condition. Now, when those situations arise, the customer is taking into account how the company is responding to those situations. If the client has the feeling that he is putting more effort in fixing the problem than the company, then he is way more inclined to spread the word about his bad experience to others, while also being more prone towards switching brands altogether.

Mar 27 2019
Mar 27

Every store owner dreams that their shopping cart stay full of goods and successfully proceeds to checkout. There are some general shopping cart tips to achieve this. Today, we will focus on Drupal Commerce stores that have many ways to make your cart convenient and attractive. To implement them, there are useful Drupal 8 modules for your  Drupal Commerce shopping cart, which we will review right now.

The built-in Drupal Commerce shopping cart

Drupal Commerce 2.x for Drupal 8 online stores comes with a full-fledged shopping cart. It offers a add-to-cart form, which allows customers to add and remove goods.

The add-to-cart form is customizable and fieldable. It is found on the "Manage form display" tab of the “Order item types” section. You can enable the product quantity field, the unit price field, and add more fields.

The form can be attached to content types as referenced entity, so that you can, for instance, post articles with the option to buy a product.

Drupal Commerce 2 offers a shopping cart as a block that can be put anywhere on your website. The shopping cart contents can show on every page. The cart can also be customized via Drupal 8 core Views.

HTML and CSS can further customize its display. Finally, extra features can be added by contributed modules.

Useful Drupal 8 contributed modules for Drupal Commerce shopping cart

Commerce Cart API

The Commerce Cart API module was introduced at Drupal Europe in Darmstadt by its creator, Matt Glaman of Commerce Guys. In his speech “The road to a headless Drupal Commerce future” he emphasized the importance of JavaScript-based e-commerce solutions.

As Matt also wrote in his article, the Commerce Cart API module improves the shopping experiences by providing users with progressively decoupled components.

The module offers lightweight RESTful endpoints for dynamic shopping cart interfaces. Its default implementation is the Commerce Cart Flyout module.

Commerce Cart Flyout

The Commerce Cart Flyout module uses progressive decoupling principle to give users modern cart update experiences.

It provides a flyout sidebar that shows whenever a user clicks on the shopping cart block or presses the “add to cart” button. The user can view the cart contents, change the product quantities, or remove products without the page reload.

The module’s JavaScript logic is built on Backbone.js and Underscore.js, which provides for a very clean structure. According to Matt Glaman, they were chosen because they ship with Drupal core. The module is highly customizable and offers nine ready Twig templates.

Commerce Ajax Add to Cart

The Commerce Ajax Add to Cart for Drupal Commerce shopping cart is a popular module with 25,420+ total downloads, but it is in the beta stage for Drupal 8. With it, the add-to-cart actions are performed using AJAX. The shopping items are updated with no page refresh, and a popup message shows when a new product is added.

Ajax Add to Cart

Here is another module that ajaxifies the process of adding products to cart. This is the Ajax add to Cart module for Drupal 8 shopping cart. When a user adds a product, a popup is instantly generated, and the shopping items are updated.

Commerce Variation Cart Form

The Commerce Variation Cart Form module provides an add-to-cart form for individual entities of product variations. The form is added to product variations as a field.

This is useful when you need to display individual entities with its own add-to-cart functionality. You can also replace the standard Drupal Commerce add-to-cart form with them.

Commerce Add To Cart Link

With the Commerce Add To Cart Link Drupal 8 module for Drupal Commerce shopping cart, you can have the “add to cart" field as a link instead of a form. A common use case is to display the link on product listings (overviews, related products, and so on).

The link is rendered via Twig template, which lets developers feel free in customization. The module has a submodule Commerce Add To Wishlist Link that provides a link for adding products to your wishlist with the Commerce Wishlist module.

Commerce Combine Carts

The Commerce Combine Carts combines multiple shopping carts of the user into one. The module is in the beta version for Drupal 8.

It works in two ways:

  • combines all of a user’s order items into this user’s main shopping cart
  • combines all of a user’s shopping carts into one when the user logs in

Let’s shape your Drupal Commerce shopping cart and whole store

Our Drupal team is ready to help you use these and other modules, or create custom ones for your Drupal Commerce shopping cart. We can also build you a Drupal 8 online store from scratch or optimize your existing one. Contact us!

Mar 27 2019
Mar 27

Less than two weeks remain until the start of DrupalCon Seattle and the Event Organizers have a packed schedule. We’ve been meeting virtually throughout the year, and we’re all looking forward to the opportunity to meet in person and dig into the conversations further. Here’s a list of where we’ll be—from “official” organizer events, to sessions and BoFs that are of interest for organizers. Whether you’re an event organizer, interested in starting an event in your area, or just want to flag one of us down, here’s where to look.

Tuesday, April 9

Wednesday, April 10

Thursday, April 11

Thanks to Kaleem Clarkson (of DrupalCamp Atlanta) for all of his hard work on organizing the organizers and John Rearick (of DrupalCorn) for digging through the schedule to find many of these sessions.

We'll see you at DrupalCon!

Mar 27 2019
Mar 27

What is govCMS?

The govCMS distribution is supported in Drupal 7 and Drupal 8 version, which has installation profiles for Australian government websites and it is being actively managed on Github (https://github.com/govCMS/govCMS8) and features are maintained from https://www.govcms.gov.au/.
 

To work with govCMS, we have to take care of some factors in order to create a site with the govCMS platform.
 

They have limited number of the module they support and we have to stick to that only and need to find alternate options with the twig and preprocess functions only and they do not allow us to create custom modules as well.
 

Here is the list of modules that they support: https://www.govcms.gov.au/govCMS-d7-modules
 

Unfortunately supported modules for Drupal 8 are less compare to Drupal 7, but we can create support request of community and if it's valid then they can include a module on SaaS platform.
 

Our Experience about working with govCMS

We have worked with govCMS for one of our clients from Australia, who is working with another agency before we met, and already he had started site development with them, and fortunately, he gets to know about the quality of work done so far from the previous agency.

They have added lots of contrib modules and to achieve some functionality they have created custom modules as well, but as the govCMS platform doesn't support such modules we have to flush out all existing implementation and started from the beginning.

All features which are build using custom/contrib modules, we had to find alternatives and get things done only with supported modules and using preprocess functions and twig alters. and along with that, we have to make sure that site is WCAG compliance as it is a government website they must be. So all things we delivered to the client successfully as per the client's expectation with the boundary of govCMS restriction.


 

More details about what is govCMS

Drupal gets big in the Australian Government
 

With almost half of Australian Government departments now running Drupal, and hundreds of more sites now live within various agencies, Drupal has transformed the way government websites are built and managed.
 

Drupal 7: https://www.drupal.org/project/govcms

Drupal 8: https://www.drupal.org/project/govcms8
 

The aim is to provide a single solution for unclassified websites using a common codebase and a shared feature set on a scalable and secure list infrastructure.

govCMS distribution is supported as SaaS by amazeelabs in collaboration with govCMS community and it supports several contributed modules which are available, here is a list of modules which can be used with SaaS https://www.govcms.gov.au/govCMS-d7-modules.
 

Workflows and Ahoy

It is interesting to see that the .ahoy.yml is just a set of command shortcuts, which is similar to the scripts section of a composer.json. Every implementation can be smoothed over by a single Ahoy command, and the underlying implementation can evolve without the developer even noticing.

Speculating, I think the hardest part about adding Ahoy commands will be naming them. Even then, the govCMS team will have the luxury of focussing on the "SaaS govcms 8 on Lagoon" use case, rather than something like BLT which attempts to have commands for "any Drupal anywhere".

Mar 27 2019
Mar 27

Drupal 8 has a multitude of field types to cover a large number of use cases and situations when it comes to structuring and modeling content. Among these, we have a List field type which, as its name suggests, allows us to configure an input field based on a list of predefined options. This list of options must be set manually in the field's storage options at the time of creation.

But we can also use this field based on a list of options that can be provided dynamically. Let's look at how we need to proceed to have a field that allows us to choose from a list of dynamic options.

For the example, we will create a list field that will provide us with a list of all content types available on a Drupal 8 project. The creation of such a field will take place in 4 steps.

  1. Creating the field with an empty list of options
  2. Export of the field configuration
  3. Modification of the field configuration by associating a function to it to provide the list of options
  4. Importing the new field configuration

Creating the List field

Creating such a field is quite simple. Let's add a field called Content type (machine name field_content_type) on a paragraph type for example.

add field list type

Et laissons les options de champs vide.

Field list settings empty

Exporting the field configuration

We can export the configuration of the new field, with the drush cex command, or with the Features module, or using the configuration export interface available natively with Drupal Core.

We get this configuration for our new field

langcode: fr
status: true
dependencies:
  module:
    - options
    - paragraphs
id: paragraph.field_content_type
field_name: field_content_type
entity_type: paragraph
type: list_string
settings:
  allowed_values: {  }
  allowed_values_function: ''
module: options
locked: false
cardinality: 1
translatable: true
indexes: {  }
persist_with_no_fields: false
custom_storage: false

Changing the field configuration

We then edit this field configuration to associate a function on the allowed_values_function parameter. This function will be in charge of providing a dynamic list of possible options, namely the different types of content present on the project.

Our configuration then becomes

langcode: fr
status: true
dependencies:
  module:
    - options
    - paragraphs
id: paragraph.field_content_type
field_name: field_content_type
entity_type: paragraph
type: list_string
settings:
  allowed_values: {  }
  allowed_values_function: my_module_allowed_values_bundle
module: options
locked: false
cardinality: 1
translatable: true
indexes: {  }
persist_with_no_fields: false
custom_storage: false

Of course, we must now create this function in the my_module module.

/**
 * Set dynamic allowed values for the bundle field.
 *
 * @param \Drupal\field\Entity\FieldStorageConfig $definition
 *   The field definition.
 * @param \Drupal\Core\Entity\ContentEntityInterface|null $entity
 *   The entity being created if applicable.
 * @param bool $cacheable
 *   Boolean indicating if the results are cacheable.
 *
 * @return array
 *   An array of possible key and value options.
 *
 * @see options_allowed_values()
 */
function my_module_allowed_values_bundle(FieldStorageConfig $definition, ContentEntityInterface $entity = NULL, $cacheable) {
  $entity_type_id = 'node';
  $options = [];
  /** @var \Drupal\Core\Entity\EntityTypeBundleInfoInterface $entityBundleInfo */
  $entityTypeBundleInfo = \Drupal::service('entity_type.bundle.info');
  $entity_type_bundles = $entityTypeBundleInfo->getBundleInfo($entity_type_id);

  foreach ($entity_type_bundles as $key => $entity_type_bundle) {
    $options[$key] = $entity_type_bundle['label'];
  }
  return $options;
}

Importing the new field configuration

We can then import this new configuration using the drush cim command, or using the Features module or from the configuration import interface, depending on your project, whether it is a simple site or a Drupal 8 web factory.

And the trick is done. Now the configuration of the field indicates that the list of options is provided dynamically.

Liste des types de contenu

And you can now offer a selection from the different content types on the site. This type of implementation is particularly effective when it comes to making components, whatever they are, which can then be used on any type of project, from a simple site, to a complex site or a Drupal 8 web factory.

Mar 26 2019
Mar 26

When it comes to testing in software development, the range of options is huge. From unit testing on the backend through browser compatibility testing on the front end, there are a variety of testing approaches that will save you, your clients, and their audiences, time and headache. Katalon Recorder is a quick, simple way to get started with testing and to see the value that automated tests provide within a matter of minutes.

What is Katalon Recorder?

Katalon Recorder (KR) is a Selenium-driven browser plugin for Chrome and FireFox that lets you control your browser with simple commands instead of actual clicking, typing, tabbing, and scrolling. Put simply, KR can interact with your web application and report back when things don’t go as planned. Katalon Recorder aims to emulate human actions such as clicking, typing, and verifying the status of onscreen content - and as such works very well as an automated replacement for human testing.

How does it work?

With Katalon Recorder, you can record your browser actions - such as clicking through your menu items - and then play those actions back as automated commands. You can also handcraft a wide variety of commands that assert the existence of HTML elements or copy, among a host of other things. The successful playback of well crafted tests indicates that your menus, content, and HTML structure haven't changed — in other words your application is behaving as expected.

Katalon Recorder

The Basics: Record and Playback

After clicking Record KR will bring your browser into focus, then log all of your interactions as individual commands. Once Stop is clicked, those commands can be played back, saved to a file, shared with others to play in their browsers, or modified to fine-tune functionality. With Katalon Recoder’s Record feature setting up initial tests that mirror human-driven clickthroughs takes moments of your time and can then be played back by anyone anywhere — including non-technical staff or even client teams.

Katalon Recorder

Creating Complex, Rigorous Tests

Katalon Recorder allows you to organize one or more individual commands as Test Cases, and one or more Test Cases as Test Suites. Complicated tests can be created by chaining together several Test Suites. You could, for example, write tests that log a test user in, search for a product by SKU, click into the results, add the product to their cart, navigate to the cart and assert the product is there, then complete the purchase using test financial data. All of those actions except assert the product is in the cart can be recorded from your interactions. That means that in many cases, the amount of time that it takes for you to perform an action on your website is, using the recorder feature, the amount of time it takes you to write the automated test.

Flexibility Via Hand-Crafted Commands

In some cases the rigidity of recorded actions is a drawback. If, for example, you want to search for the tag Home Appliances and then click into the product Test Toaster, but you aren’t sure where in the search results that item will be, a recorded action informed by precise HTML structure might fall short. In those cases, you can use a combination of CSS and XPATH selectors to find and interact with your elements regardless of where exactly in the DOM they exist.

Katalon Recorder

Storing Variables with Javascript

Sometimes a human tester needs to remember something, like the name or unique ID of a piece of content, in order to proceed with their test. Let’s say, for example, you’re testing a Drupal site wherein you first want to create a new Person node, then associate it via an entity reference field with a Group node on that node’s creation form. Using Katalon Recorder’s storeEval command you can use Javascript to accomplish that by saving a variable.

Once you have saved the form for your Person node, you’ll get redirected to something like http://mysite.dev/node/887 where 887 is the node ID for your content. The storeEval command lets you save the ID number to a variable that we can access later in our tests. See the image below:

Katalon Recorder

Katalon Recorder covers a lot of bases. Whether you're using just the Record option for building basic spot-checks, or combining advanced features to create rigorous and complex functional testing, it's surprising what can be achieved in so little time — especially given KR's very tenable learning curve. While the examples above are exceedingly simple, in some recent projects we’ve combined thousands of commands across dozens of test cases that provide thorough regression testing and automated QA — and it all started with the click of a Record button.

Mar 25 2019
Mar 25
You can make the most elegant, relevance-based site search appliance possible -- but, still, sometimes you’re going to want to ‘game’ the system. Manipulating site search results sounds nefarious, but really it’s all about providing the most…
Mar 22 2019
Mar 22

Each year, there’s a plethora of various tech and business events all over the world, even if we disregard the numerous Drupal events. In fact, there are so many of these conferences dispersed throughout Europe, the Americas and the Asia Pacific region that you can never even dream of attending all of them (in some cases, you’d actually need some kind of time machine!). But how do you find the ones that you or your agency would really profit from attending?

At Agiledrop, we’ve been asking ourselves the same question. Even though some of the biggest tech conferences of 2019 have already taken place (e.g. January’s CES which took place in Las Vegas), this doesn’t mean that you or your agency have to miss out on great networking and business opportunities at such gatherings. With spring already begun, there’s a huge number of relevant events you can (and should!) check out. 

For this reason, we’ve done some research and have attempted to make a more narrow list of the absolutely-don’t-miss tech and business events from March until the end of 2019. This narrowing down is also the reason why we decided to exclude all the Drupal events - we believe the community is already pretty well informed on these, but perhaps not so much on non-Drupal ones.

We hope you’ll be able to make a more informed decision after reading our list. Best case scenario - you won’t have to convince your boss as vehemently after telling them about all the benefits of specific events and all the amazing speakers you would miss.

So, without further ado, here’s a list of events for agencies to attend in 2019 that stood out to our team the most. 

1. OutBound (April 23-26, Atlanta, Georgia, USA)

With over 1200 yearly attendees from all over the globe and a lineup of renowned professional speakers, OutBound is one of the hottest Sales conferences you can attend. 

Such a high number of prestigious speakers coupled with the huge focus on catering to the audience make OutBound the perfect event for sales executives or even entire sales teams to attend. 

Among this year’s speakers are Bob Burg, with the sales total for his books on sales, marketing and influence well exceeding 1.5 million copies; Meridith Elliott Powell, featured sales expert for the LinkedIn Learning Platform and award-winning author, keynote speaker and business strategist; Anthony Iannarino, another acclaimed international speaker and bestselling author; and many others.

For the full list of speakers and information on tickets and accommodation, see the event’s website

2. Gartner Marketing Symposium/Xpo 2019 (April 29-May 1, San Diego, California, USA)

Gartner’s Marketing Symposium/Xpo is an event dedicated mostly to marketers, particularly CMOs and other marketing leaders. You’ll get a chance to network and exchange ideas with over 1,500 like-minded attendees, as well as expand your professional experience. 

Marketing is a field where trends are constantly shifting and evolving, and one must remain vigilant and keep track of the latest technologies and practices. The 2019 symposium aims to help with exactly that; with the sessions covering a whole range of marketing topics, attendees will have a greater insight into the different trends and consequently will be better equipped to tackle change when it comes (and it will come!).

Perhaps the most appealing thing about Gartner’s event are the exhibitors. Next to major players such as Adobe and Salesforce you’ll also find the leading Drupal company, Acquia

Check out the event’s website for a full list of exhibitors, speakers, schedules for each day and pretty much anything else you might want to know about.  

3. The Next Web Conference (May 9-10, Amsterdam, The Netherlands)

TNW Conference is one of the leading events in Europe celebrating technological innovation. This year will mark the 15th consecutive edition of the conference; over the past 15 years, the event has grown from only about 200 to over 17,500 attendees for each day, making it one of the biggest European tech conferences.

The topics and sessions of TNW Conference are quite broad; anyone working in any kind of tech industry will surely find something for themselves. Topics range from marketing, business, digital product development, emerging technologies, women in tech, commerce, and many more. 

This year’s speakers include: Gordon Willoughby, CEO of WeTransfer; Gillian Tans, CEO of Booking; Chris Slowe, CTO of Reddit; … you know what? There are too many awesome ones to list them all - check them out for yourself here!  

4. Mirren Live New York (May 14-15, New York City, New York, USA)

Also dubbed the “agency growth conference”, Mirren Live New York is the perfect event for agencies to attend. It is a chance to meet representatives from numerous globally-recognized names and learn the latest agency trends. 

Their website claims that this year’s lineup is “killer” - and that’s a pretty appropriate description. Just quickly going through the list, we don’t even know where to start - we might as well just list them all. So, go ahead and see the whole list for yourself. 

In case you really do want to catch all the sessions, or prefer leveraging your presence there to make new business connections, it’s also possible to purchase access to the broadcast of most of the sessions. This is also ideal for anyone who won’t be able to make it but also won’t want to miss the speakers.

5. Adobe Summit EMEA (15-16 May, London, UK)

This is the EMEA version of the Adobe Summit, with the North American equivalent taking place this weekend. The focus of the event is on experience marketing - an area that’s becoming more and more relevant, with customers’ and users’ increasing demand for (unforgettable) experiences.

Still, it is an event that will inspire anyone working in marketing. You can personalize your weekend by choosing between more than 120 sessions by fascinating speakers, among whom are Senior Vice President at Magento and Adobe, Mark Lavelle; Digital Project Manager at Capgemini, Kelly Derickx; Vice President EMEA at Twitter, Bruce Daisley; and countless more. 

If you or your company use Adobe products, attending is almost a must, as you’ll get first-hand insights into Adobe’s latest technologies and practices in experience marketing. Here you can check the reasons for attending, with a bonus email template for more easily convincing your boss.  

6. AA-ISP Digital Sales World (different dates and locations)

AA-ISP (The American Association of Inside Sales Professionals) is a global association focusing on Inside Sales. Each year, they organize their one-day Digital Sales World event with four different dates and locations. This is great news for everyone wanting to attend - you have four options to pick from, which ensures that you won’t miss out.

The dates are the following:

  • May 14, London, UK
  • June 13, Dallas, Texas, USA
  • September 12, Norwood, Massachusetts, USA
  • December 3, Dublin, Ireland

It is a digital sales world conference where sales leaders and other industry experts come together for a day packed with learning, networking and getting to know new sales tools and technologies. 

A lot of the speakers are already known; judging from these lineups, it’ll be hard to decide on a single instance to attend. You can check out the main page of the event to get more information and make a more informed choice.

7. SaaStr Europa (June 12-13, Paris, France)

Even though SaaStr Annual in San Francisco already took place in February, you still have plenty of time to plan for and attend the European variant of the event. 2018 was the inaugural year for SaaStr Europa, and it returns to Paris in 2019 with double the content and almost double the number of attendees compared with last year.

SaaStr Europa is thus the perfect opportunity to learn from and network with a wide range of SaaS experts from all over the world. The impressive lineup of speakers includes Christina Bechhold Russ, Principal at Samsung NEXT; Jane Kim, VP of Revenue at CircleCI; the co-founder of Saastr, Jason Lemkin; and many others. 

For a full list of speakers, sponsors and more information on tickets, visit the event site itself.

8. MozCon (July 15-17, Seattle, Washington, USA)

MozCon is a conference organized by the SEO-centric company Moz. As a consequence, the event puts great emphasis on SEO; but, more broadly, it’s an event for any kind of marketer, exploring topics such as branding, user and customer experience, analytics, and content marketing.

The 2019 speakers list features a number of Moz employees, such as CEO Sarah Bird, and other industry experts, such as Head of PR & Content at Aira, Shannon McGuirk. You can check out the full list here.

So - you definitely won’t want to miss MozCon. No matter where in the digital sphere you’re positioned, SEO is a field you’ll always have to keep up-to-date with. Add to that the impressive lineup of speakers and the unique opportunity to connect with leading industry experts and agencies, and you know where you’ll be going this July.

9. INBOUND (September 3-6, Boston, Massachusetts, USA)

INBOUND is HubSpot’s annual conference for sales and marketing enthusiasts. It is an event that puts emphasis on human interaction, where attendees view each other as peers rather than competition, and consequently help each other learn and improve.

The speakers at INBOUND’s sessions are perhaps the highlight of the conference. While speakers for 2019 have not yet been announced, previous years’ speakers include names such as Michelle Obama, Deepak Chopra and Gary Vaynerchuk

Besides all the educational sessions, INBOUND also offers attendees non-business entertainment with performers such as Judd Apatow and Amy Schumer. The agenda for this year has yet to be announced; we’ll make sure to update this post with fresh information. Meanwhile, you can find out more about INBOUND here

10. Dreamforce (November 19-22, San Francisco, California, USA)

Dreamforce is the annual event of the American cloud-based software company Salesforce. Its roots going back as far as 2003, Dreamforce was one of the early B2B conferences - and a relatively small one, at that, with just over 1000 attendees. 

Fast forward a little more than 15 years and Dreamforce is one of the largest B2B events in the world, boasting almost 200,000 attendees and over 2,000 sessions in 2018. 

Even if you don’t use Salesforce or any other cloud products, with such an abundance of options, you’ll definitely find something for you. At the very least, you’ll have the one-of-a-kind opportunity to connect with some of the biggest names in the digital industry and forge new business relationships.

You’ve definitely heard of companies such as IBM, Deloitte Digital and Accenture. Well, these are just the tip of the iceberg of Dreamforce’s sponsors. Additionally, going through the list of last year’s speakers, you’ll stumble upon names such as Arianna Huffington, founder of the Huffington Post and Thrive GlobalOscar Munoz, CEO at United Airlines; and even Al Gore, former US vice president and known environmentalist. 

If you’re still not convinced, check out Dreamforce’s official site for any additional information. You can even calculate the ROI of attending to make a better case to your boss!

11. The Drum Awards

The Drum is Europe’s largest marketing platform, so their annual awards are definitely the place to meet the cream of leading industry professionals. It is a chance for outstanding businesses to get their deserved recognition, which also helps them attract new talented employees.

What’s really great about The Drum’s awards is that they showcase success in all areas of digital and marketing, enabling you to cherry-pick the ones you want to attend and/or the ones most relevant to your position and interest. 

You can view a full list of the awards here. So far, only the dates for the Marketing Awards ceremonies are known:

  • Europe: April 3, London, UK
  • USA: April 11, New York City, New York 

We’ll make sure to update the list as soon as the dates and locations are announced. Meanwhile, you can get a better feel of The Drum Awards by checking out the highlights from last year’s marketing award ceremony.  

Honorable mentions

Some of the don’t-miss events of 2019 have already taken place, such as the already mentioned CES. We also refrained from including events that are happening this weekend, as it would be pretty much impossible to book tickets and/or flights at this point. Nonetheless, we wanted to at least mention them, so you know which ones to be on the lookout for next year:

These were the non-Drupal-related events and conferences in 2019 that we found to be the most appealing. We hope this blog post sheds some light on which of these events you would benefit from attending so that you’ll be able to plan accordingly. We’ll update any lacking parts when more information is released. 

Mar 21 2019
Mar 21

The value that the community brings to the development of Drupal

Drupal is known for the community that it has amassed as an open source software. But what is the value that the community brings to the development of Drupal?

First off, drupal is an open source CMS. What that means is that everybody can download and mingle with it. Because of this, Drupal has gathered a community of supportive members. Soon, the community has started to actively contribute with code and ways to further developed and improve Drupal. Drupal has more than 42,000 modules that were developed by the community. On top of that, regular security issues are discovered and fixed by the members in their own free time. Also, users are taking their time to answer questions posted on forums by new members to guide them in the Drupal world. This has led Drupal to be known as one of the most active, helpful, dedicated and loyal communities in the world.

DrupalCon Nashville 2018 Copyright Amazee Labs

Photo's DrupalCon Nashville 2018 copyright Amazee Labs

We all come together at DrupalCon

So where do the members of the community spend their time when not sitting in front a of a screen coding?

Well, the biggest event of the year is the DrupalCon. Every year it takes place in another location. With two conventions scheduled for 2019, one in sleepless Seattle and the other in incredible Amsterdam, DrupalCon is sure to gather a big crowd this year. Activities which are scheduled include keynotes with inspiring figures from inside and outside the community, trainings, summits, birds of a feather meetings and diverse social events.

DrupalCon is a great opportunity to meet and connect with new people, while acquiring more knowledge about Drupal and the direction it's heading in. On top of that, there is a chance of engaging into conversation with highly skilled people with expert knowledge in their domain, which can guide you and give you tips and tricks on what to do. So, if you’re a Drupal enthusiast, be sure to grab a ticket, pack your luggage and join the biggest Drupal social event of the year.

DrupalCon Nashville 2018 Copyright Amazee Labs

Photo's Drupal Camp Vienna 2015 copyright Amazee Labs

Cosy get-togethers in Drupal Camps

Now that we talked about the biggest social event of the year, Drupalcon, we can take a look at what the Drupal community is doing for the rest of the year. The community also organises smaller events, throughout the year, for regional groups of people. These meetings are more frequent than the DrupalCons. The activities which are undertaken in those camps are usually talks held by speakers on different subjects of interest to the community. The camps also offer training talks for beginners. The main focus of these type of events is to find out more about Drupal, share your Drupal experience and also to meet the local Drupal community.

List upcoming Drupal camps:

Name of the Camp Date Location Nerd Summit 2019 16-17.03.2019 United States, Amherst MidCamp 2019 20-23.03.2019 United States, Chicago Frone End Accesibility Summit 08.04.2019 United States, Seattle DrupalCamp Spain 6-12.05.2019 Spain, Conil de la Frontera Drupaldelphia 10.05.2019 United States, Philadelphia Secure Open Source Day - Haarlem Edition 11.05.2019 Netherlands, Haarlem Stanford DrupalCamp 17-18.05.2019 United States, Stanford Frontend United 17-18.05.2019 Netherlands, Utrecht DrupalCamp Belarus 17-18.05.2019 Belarus, Minsk DrupalCamp Kyiv 25-26.05.2019 Ukraine, Kyiv Flyover Camp 31-02.06.2019 United States, Kansas City DrupalCamp Poland 31-02.06.2019 Poland, Wrocław Drupal Developer Days 10-14.06.2019 Romania, Cluj-Napoca Save the Date - Design 4 Drupal Boston 26-28.06.2019 United States, Cambridge DrupalCamp Asheville 2019 12-14.07.2019 United States, Asheville DrupalCamp Colorado 02-04.08.2019 United States, Denver Cornell DrupalCamp 26-27.09.2019 United States, Ithaca DrupalSouth Hobart 27-29.11.2019 Australia, Hobart

How are new Drupal users integrated?

Now that we know how the Drupal community likes to spend its time, we can have a look at how the newcomers are being integrated in the community. First, the newbies can attend training sessions which are held on multiple occasions over the course of the year, with different locations. So, if you’re getting an interest in Drupal but don’t know where to start, you can search for the nearest Drupal beginner onboarding camp to find more about Drupal and the Drupal community. On top of that, you can also rely on the Drupal community forums by posting questions there and letting a more experienced user answer your question.

DrupalCon Nashville 2018 Copyright Amazee Labs

Community spotlight photo collection, indidual images' rights belong to their respectful owners. Collage created by Sooperthemes and licensed under a Creative Commons Attribution 4.0 International license.

Drupal community spotlight

Drupals open source means that everybody can get involved, making the community vibrant and full of inspirational stories. The community has the spotlight section where there are numerous articles about different members of the community and their journey from being a beginner to a well respected member and contributor.

Ildephonse Bikino

Another inspiring story is that of Ildephonse Bikino. He discovered Drupal through his job. He had the opportunity to attend the DrupalCon from 2016 held in New Orleans via a scholarship provided by the Drupal Association. There, he saw the opportunities that the open source software can bring. This led him to host his first Drupal Global Training Day in Rwanda, where he was expecting a number of 50 atendees. However, to his surprise, this number quickly grew and he had a list of 388 participants. Not wanting to turn his back on the Drupal enthusiasts he rose to the challenge and transformed a one day training into eight sessions spread across multiple weekends. This way, he made sure that every Drupal enthusiast received a proprer training. His dedication to the cause is what makes him a trully inspiring person and gives us a reason to tell his story.

Kevin Thull

Another great spotlight is the one about Kevin Thull. He got involved into Drupal through freelancing and started really getting involved with the community by the time the book Using Drupal 6 came out. He is known for being the mastermind behind the recording of the different Drupal events. He started recording drupal camps back in 2013. At first, everybody questioned his decision, however, he stayed true to his belief, that it is important to record those events. To date, he is personally responsible for recording over 800 sessions and giving up countless of hours of his time to achieve this feat. He was awarded with the Aaron Winborn Award in 2018 for his contribution to the Drupal community.

Rachel Olivero

For example, we have the case of Rachel Olivero which has recently passed away. She first started getting involved with the community at the DrupalCon 2017 in her hometown of Baltimore, where she participated for the first time in a code sprint and also reported her first bug. She was engaging constantly with the community on social platforms. As a blind person, she led an accesibility breakthrough at DrupalCon Nashville. She was always sharing her knowledge and expertise regarding this topic. Her aim was to make life easier for the users with disabilities. She understood the importance of diversity and so she was also engaged with the Drupal Diversity and Inclusion Team. Although she was part of the community for a short period of time, she left her mark through her actions and her contributions.

Aaron Winborn and the award named after him

The Aaron Winborn Award, also known as the “Academy Award” of the Drupal Association is an honor given to the members of the Drupal community that show personal integrity, kindness and an above-and-beyond commitment to the community. It was named in the honor of Aaron Winborn, a big community contributor which passed away after losing a battle with Amyotrophic Lateral Sclerosis. A specific disease which causes the death of the neurons that are controlling voluntary muscles. In order to remember the contribution which Aaron Winbord has brought to the Drupal community, the award was named after him after his death in 2015. To date, the award was given to 4 people which had a big contribution to the community and namely Cathy Theys, Gábor Hojtsy, Nikki Stevens and Kevin Thull. Right now, the nominations for the next awarding are open, so be sure to nominate your favourite member of the Drupal community.

Conclusion

In conclusion, the community is of utmost importance to the development of Drupal. The community is what keeps the CMS alive, while also in a costant state of evolution. Drupal has made it possible for people of different cultural backgrounds to cooperate and stand united for the same cause.  This reflects well on the unofficial motto ,"Come for the code, stay for the community".

Mar 21 2019
Mar 21

Since our initial release, we’ve been doing agile, iterative development on the software. Working with our partners at the University of Michigan and the State of Georgia, we’ve made refinements to both the application and the Drupal integration.

Better search results

Default searches now target the entire index and not the more narrow tm_rendered_item field. This change allows Solr admins to have better control over the refinement of search results, including the use of field boosting and elevate.xml query enhancements.

Autocomplete search results

We added support for search autocomplete at both the application and Drupal block levels -- and the two can use the same or different data sources to populate results. We took a configurable approach to autocomplete, which supports “search as you type” completion of partial text. These results can also include keyboard navigation for accessibility.

Since the Drupal block is independent of the React application, we made it configurable so that the block can have a distinct API endpoint from the application. We did this because the state of Georgia has specific requirements that their default search behavior should be to search the local site first, looking for items marked with a special “highlighted content” field.

Enter search terms field with list of suggested results

Wildcard searching

We fully support wildcard searches as a configuration option, so that a search for “run” will automatically pass “run” and “run*” as search terms.

Default facet control

The default facets sets for the application -- Site, Content Type, and Date Range -- can now be disabled on a per-site basis. This feature is useful for sites that contribute content to a network but only wish to search their own site’s content.

Enhanced query parameters

We’ve added additional support for term-based facets to be passed from the search query string. This means that all facet options except dates can be passed directly via external URL before loading the search form.

Better Drupal theming

We split the module’s display into proper theme templates for the block and it’s form, and we added template suggestions for each form element so that themes can easily enhance or override the default styling of the Drupal block. We also removed some overly opinionated CSS from the base style of the application. This change should allow CSS overrides to have better control over element styling.

What’s Next for Users?

All of these changes should be backward compatible for existing users, though minor changes to the configuration may be required, Users of the Drupal 8.x-2.0 release will need to run the Drupal update script to load the new default settings. Sites that override CSS should confirm that they address the new styles.

Currently, the changes only apply to Drupal 8 sites. We’ll be backporting the new features to Drupal 7 in the upcoming month.

Users of the 1.0 release may continue to use both the existing Drupal module and their current JS and CSS files until the end of 2019. We recommend upgrading to the 2.0 versions of both, which requires minor CSS and configuration changes you can read about in the upgrade documentation.

Special Thanks

Palantir senior engineer Jes Constantine worked through the most significant changes to the application and integration code. Senior front-end developer Nate Striedinger worked through the template design and CSS. And engineer Matt Carmichael provided QA and code review. And a special shoutout to James Sansbury of Lullabot -- our first external contributor.

Mar 21 2019
Mar 21

The JSON:API module was added to Drupal 8.7 as a stable module!

See Dries’ overview of why this is an important milestone for Drupal, a look behind the scenes and a look toward the future. Read that first!

Upgrading?

As Mateu said, this is the first time a new module is added to Drupal core as “stable” (non-experimental) from day one. This was the plan since July 2018 — I’m glad we delivered on that promise.

This means users of the JSON:API 8.x-2.x contrib module currently on Drupal 8.5 or 8.6 can update to Drupal 8.7 on its release day and simply delete their current contributed module, and have no disruption in their current use of JSON:API, nor in security coverage!

What’s happened lately?

The last JSON:API update was exactly two months ago, because … ever since then Gabe, Mateu and I are have been working very hard to get JSON:API through the core review process. This resulted in a few notable improvements:

  1. a read-only mode that is turned on by default for new installs — this strikes a nice balance between DX (still having data available via APIs by default/zero config: reading is probably the 80% use case, at least today) and minimizing risk (not allowing writes by default)
  2. auto-revisioning when PATCHing for eligible entity types
  3. formally documented & tested revisions and translations support
  4. formally documented security considerations

Get these improvements today by updating to version 2.4 of the JSON:API module — it’s identical to what was added to Drupal 8.7!

Contributors

An incredible total of 103 people contributed in JSON:API’s issue queue to help make this happen, and 50 of those even have commits to their name:

Wim Leers, ndobromirov, e0ipso, nuez, gabesullice, xjm, effulgentsia, seanB, jhodgdon, webchick, Dries, andrewmacpherson, jibran, larowlan, Gábor Hojtsy, benjifisher, phenaproxima, ckrina, dww, amateescu, voleger, plach, justageek, catch, samuel.mortenson, berdir, zhangyb, [email protected], malik.kotob, pfrilling, Grimreaper, andriansyahnc, blainelang, btully, ebeyrent, garphy, Niklan, joelstein, joshua.boltz, govind.maloo, tstoeckler, hchonov, dawehner, kristiaanvandeneynde, dagmar, yobottehg, [email protected], keesee, caseylau, peterdijk, mortona2k, jludwig, pixelwhip, abhisekmazumdar, izus, Mile23, mglaman, steven.wichers, omkar06, haihoi2, axle_foley00, hampercm, clemens.tolboom, gargsuchi, justafish, sonnykt, alexpott, jlscott, DavidSpiessens, BR0kEN, danielnv18, drpal, martin107, balsama, nileshlohar, gerzenstl, mgalalm, tedbow, das-peter, pwolanin, skyredwang, Dave Reid, mstef, bwinett, grndlvl, Spleshka, salmonek, tom_ek, huyby, mistermoper, jazzdrive3, harrrrrrr, Ivan Berezhnov, idebr, mwebaze, dpolant, dravenk, alan_blake, jonathan1055, GeduR, kostajh, pcambra, meba, dsdeiz, jian he, matthew.perry.

Thanks to all of you!

Future JSON:API blogging

I blogged about once a month since October 2018 about JSON:API, to get more people to switch to version 2.x of the JSON:API module, to ensure it was maximally mature and bug free prior to going into Drupal core. New capabilities were also being added at a pretty high pace because we’d been preparing the code base for that months prior. We went from ~1700 installs in January to ~2700 today!

Now that it is in Drupal core, there will be less need for frequent updates, and I think the API-First Drupal: what’s new in 8.next? blog posts that I have been doing probably make more sense. I will do one of those when Drupal 8.7.0 is released in May, because not only will it ship with JSON:API land, there are also other improvements!

Special thanks to Mateu Aguiló Bosch (e0ipso) for their feedback!

Mar 21 2019
Mar 21
  • Shriganesh
  • 21/03/2019

B2B and B2C DO NOT EXIST anymore. It is time businesses realise this…..

As a business, when you label an individual as your consumer, there is a very common disconnect which classifies you as a B2C brand. However, the distinction between B2C and B2B is no longer a thing in the market. These days, companies climb the success ladder or fail, based on their ability to build and maintain a long lasting personal relationship with individuals.

Energised by tech innovations, individuals today have very high expectations about what makes a great customer experience and fail to have patience for businesses that do not deliver. This has depicted the interdependence between two major business groups in the industry: B2B & B2C. The growing trends have democratised the marketplace and bridged the digital divide, giving rise to the B2All (Business to All) strategy. As a result, everyone is equal in this new way of selling, whether your target audience are businesses, or an individual customer.

How does Drupal 8 fit in?

Helping organizations to keep pace with these growing demands are the content management systems, which play a key role in presenting businesses in front of audiences, connect with leads, convert these leads into customers, and keep customers coming back.

With robust and flexible infrastructure, innovative design and some great out of the box features, Drupal CMS is one of the top web solutions considered by businesses around the world to stay abreast with the surge in demand for personalization, interactivity and scalable tools. However, it turns out that a lot of marketers are quite unfamiliar with Drupal's potential.

As a modular CMS, Drupal 8 creates tonnes of opportunities for digital marketers to integrate with marketing platforms and configure the website to act as a central node for the entire digital marketing ecosystem.

This makes things a lot easier for marketers, allowing them to manage everything from the admin interface of Drupal CMS.

Serve Every Platform

The digital economy has exploded in the past decade, and everyone connects to you with a device of their choice. As a business, you cannot channel your efforts to be picky about your online platform, and whom it will serve. One study found that on an average, more than 55% of the users won't recommend a business with a poorly designed mobile site.

With its customisable features and the ability to create responsive websites or web applications, Drupal 8 is the CMS that can adapt your business to any modern device without any hassles.

Seamless Experience

Remember the last time you saw a restaurant ad on a website, and you looked it up on your mobile device? Only to find that the site would not load because it was only readable on a 25 inch PC. Odds are that you never went back to that restaurant and you found somewhere else to go. DON'T let your business be that restaurant! Your possible customers should never pay the penalty for switching devices. Drupal 8's out of the box features lets you create impeccable user experiences on various devices, while handling all your information on the website.

Easy-to-use back-end

With a lot of information to handle, marketers often get stuck trying to handle the functionalities of the online platform, every time they have a new requirement for implementation. Sometimes they are required to remove or change some of the features/content from the back-end and their dependency on the technical team is always a big hurdle to cross.

However, with Drupal 8, things are different! Drupal CMS has a powerful back-end which can be managed without any coding skills. This gives marketers the option to handle content authoring with ease and customise accordingly.

Marketing Automation

At the end of the day, marketing strategies are all about raking in revenue by implementing these methods into your business models. And 78% of marketers believe that marketing automation systems dynamically contribute towards improving the revenue of a business.

While automation works towards driving the right crowd to your website, once the prospects arrive, these automation systems turn themselves off and it is your CMS that has to do the further talking! It plays a huge role in identifying the visitor to your website, and feeding the required data to the automated system so that further action can be taken based on their behavior.

Drupal CMS being the most scalable and flexible CMS for enterprises, has some of the best modules to integrating marketing automation tool into Drupal. Some of the best modules of Drupal 8 are Marketo, Hubspot,Pardot, and Salesforce.

Room for Infinite Growth

Also known as an "open marketing platform", Drupal CMS is a robust CMS that creates room to plan ahead for eventual growth of your marketing strategies. Built from the ground up to integrate with an endless number of marketing tools, Drupal enables you to seamlessly integrate digital marketing platforms to interoperate content and create a hassle-free experience.

Convenient Modules

Each of your marketing strategies centered around platforms such as email marketing, customer relationship management, marketing automation etc have dedicated modules that need simple configurations to set up and start working their magic with your website. These modules are an essential part of the content management system and add the extra functionality, making your online presence powerful and unique.

Over the years, Drupal CMS has evolved to become flexible, accommodating and an essential part of a marketing ecosystem. With unique capabilities like high degree of customization, scalability, better adoption, integration and more, Drupal is the most preferred choice for businesses. Add to that the rise of marketing strategies focused around the B2All business models, this content management system acts as a single platform to rule them all. Flexible design, terrific scalability, improbable features right out of the box and great security, means your depiction in the ever competent market is as unique as your brand.

Mar 20 2019
Mar 20

by David Snopek on March 20, 2019 - 4:43pm

As you may know, Drupal 6 has reached End-of-Life (EOL) which means the Drupal Security Team is no longer doing Security Advisories or working on security patches for Drupal 6 core or contrib modules - but the Drupal 6 LTS vendors are and we're one of them!

Today, there is a Moderately Critical security release for Drupal core to fix a Cross Site Scripting (XSS) vulnerability.

Folks have been asking us, so this is just a short note to say that this issue does NOT affect Drupal 6. So, you can focus just on updating your Drupal 7 and Drupal 8 sites today. :-)

Thanks!

Mar 20 2019
Mar 20
Project: Drupal coreDate: 2019-March-20Security risk: Moderately critical 13∕25 AC:Basic/A:User/CI:Some/II:Some/E:Theoretical/TD:DefaultVulnerability: Cross Site ScriptingCVE IDs: CVE-2019-6341Description: 

Under certain circumstances the File module/subsystem allows a malicious user to upload a file that can trigger a cross-site scripting (XSS) vulnerability.

Solution: 

Versions of Drupal 8 prior to 8.5.x are end-of-life and do not receive security coverage.

Reported By: Fixed By: 
Mar 20 2019
Mar 20

New to DrupalCon? We’re glad you’re joining us in Seattle!

Here are ideas to help you prepare for this exciting week among thousands of other Drupalers, while hundreds of sessions, summits, trainings, just-for-fun events, and more are all happening—some simultaneously. We have tips for during the conference and afterward, so make the most of this new experience! 

Mar 20 2019
Mar 20

Between a quarter and about a third of the content on the World Wide Web repeats itself. According to Google's head of search spam, Matt Cutts, around 25-30% of web content is duplicate. Your website is also likely to have duplicate content, even if it follows web content writing rules. In this post, we will touch upon the reasons and risks of duplication, as well as review useful modules that fix duplicate content in Drupal.

What is duplicate content?

Duplicate content is defined as identical or similar one found at different web addresses. These URLs can be within the same domain or across different ones.

Common reasons for duplicate content

Reasons for duplicate content in Drupal are pretty much the same as in other CMSs. They vary from unintentional to malicious, and from purely technical to human-created. Among the most common ones are:

  • scraped content (copied without permission)
  • syndicated content (shared by agreement)
  • HTTP and HTTPS versions of pages
  • WWW and non-WWW versions of pages
  • printer-friendly versions of pages
  • different user session IDs generating different URLs
  • almost identical product descriptions in e-commerce stores (for example, Drupal Commerce)
  • identical pieces of site-wide content (for example, in the footer)

What are the risks of duplicate content?

Duplicate content may result in losing your Google rankings. Google can’t show all duplicate results but only one from the “cluster” of duplicates. 

In addition, Google rewards uniqueness as added value. Sites with no unique content will find it harder to get good rankings.

SEO experts always take care to keep their websites from being penalized algorithmically by Google for low-quality content, including copied content. That’s why they try to keep their sites unique.

Google admits there may be strict penalties in cases when the behavior of a website with many duplicates is found to be manipulative. 

Modules that deal with duplicate content in Drupal

Getting rid of duplicates completely is neither possible nor necessary. However, there are contributed modules to deal with duplicate content  in Drupal that will make your website much cleaner from copies.

The Taxonomy Unique module

By default, Drupal allows for creating taxonomy terms with the same names within the same vocabulary. As part of measures to avoid duplicate content in Drupal 7 and 8, the Taxonomy Unique module can prohibit that.

Whenever someone tries to create a term that already exists, Drupal shows an error message saying the term name already exists. The feature can be individually enabled for each vocabulary. The error message is also customizable.

Taxonomy Unique module to fix duplicate content in Drupal


The Unique Content Title module

Thanks to the Unique Content Title module, you can require unique titles for each node of a content type. You will need to check the “Unique title” option in the “Submission form settings” of a content type. The module is only available for Drupal 7. 

The Suggest Similar Titles module

Here is another module to avoid duplication on node titles. This Drupal 7 module is at the pre-release stage for Drupal 8. 

During node creation, the Suggest Similar Titles module compares the new node titles to existing ones, and informs you if they match. The module settings allow to you:

  • decide on which content types to use the feature
  • add keywords to ignore
  • specify the allowed percentage of text matching
  • ask to check node permissions
  • limit the number of titles to show in suggestions

The Copy Prevention module

The Copy Prevention module helps you protect your texts and images from being copied on the Internet. Among the ways to do it are:

  • disabling text selection
  • disabling copy to clipboard
  • disabling right-click context menu on all content or on images
  • placing transparent image above your images
  • hiding your images from indexing 
Copy Prevention module to fix duplicate content in Drupal

The Intelligent Content Tools module

Here is an interesting module to fix duplicate content in Drupal, although it is in the development version. 

The Intelligent Content Tools module consists of three submodules. It offers auto tagging, text summarization, and duplicate content identification for your website. 

The module tells you when some duplicates have been found. Its work is based on Natural Language Processing.

Intelligent Content Tools module to fix duplicate content in Drupal


The Redirect module

The Redirect is a complex module that offers a user interface to redirect your URLs to new paths. It inherits the capabilities of the Global Redirect and the Path Redirect modules. 

Since 301 redirects and canonical URLs are among the ways to fix duplicates, the module is helpful in this sphere. It lets you:

  • manually create redirects
  • automatically redirect to canonical URLs (taking care of trailing slashes, language prefixes, and so on)
  • automatically create redirects in case of URL alias change
Redirect module to fix duplicate content in Drupal Redirect module to fix duplicate content in Drupal


The Redirect module for Drupal 8 comes with two submodules: Redirect 404 and Redirect Domain. They help you, respectively:

  • track and fix 404 errors
  • create cross-domain redirects

A bunch of other modules are recommended to use in cooperation with the Redirect:

  • Multi-path autocomplete as help with entering paths
  • Pathologic for transforming relative links in content to absolute URLs
  • Match Redirect for redirecting according to path patterns with wildcards
  • Pathauto for automatic generation of path redirects, which we will now look at more closely

The PathAuto module

The purpose of the PathAuto module is generating human-readable and SEO-friendly URLs according to chosen patterns. By default, URL aliases in Drupal look like this: /node/123. The Pathauto module can automatically change them to something like /category/my-node-title. 

The module will play an important part in website clean-up from duplicates. The Pathauto module quietly and reliably redirects URLs to the new paths based on the pattern, with no confusion for search engines or broken links for users.

Let’s fix duplicate content on your Drupal website

Each of the above modules will add a helpful touch to fixing duplicate content in Drupal. If you need help using them, or doing a comprehensive website check and clean-up with a variety of tools, feel free to contact our Drupal team. Stay unique — and both search engines and users appreciate that!

Mar 19 2019
Mar 19

In preparation for DrupalCon 2019, Chris O’Donnell, Digital Strategist, for Promet Source shared his views on the vibe of this annual conference, as well as Drupal’s current standing within the ecosystem of enterprise-level CMS platforms.  
 

What are you looking forward to at DrupalCon Seattle?

One of the best parts of DrupalCon for me is the community. It’s an opportunity to connect with people who I might only get to see once a year -- colleagues from other Drupal development companies, previous clients, current clients, and like-minded people from all over the country. There’s a ton of training and all of the sessions are driven by community involvement -- people who are just sharing their knowledge for the fun of it, or as a way to give back to the community.

Last year at DrupalCon, there was a proprietary software company exhibiting for the first time. They seemed really confused by a world where a development company was on the stage with some of its best customers. Why would anyone share great information with potential competitors? They were really confused by the entire thing - competitors coming together to openly share knowledge just didn't compute for them.

How would you explain it?

DrupalCon is more like a Drupal community celebration than a tech industry trade show. 

I think it was President Kennedy who said, “A rising tide lifts all boats,” and the same principle applies within the Drupal Community, or any open source community. The more brain power that goes into it, the better it is for everybody. As an open-source CMS, the Drupal community is driven by the community and the needs of users. Anything that anyone does to improve or add to Drupal is freely available to all. 

I joined the Drupal community in 2014, and I love being among hundreds of thousands of people around the world who contribute to the community in various ways. 


What are your observations on how DrupalCon 2019 has evolved?

There has been a pretty big shift this year as the Con has been organized around specific tracks. Drupal 8 ushered in an orientation toward more of an enterprise-level focus, and that’s been reflected in the kind of training that’s offered and an expanded sphere of people who are attending.

With so much going on, what's your advice for attendees for getting the most out of DrupalCon 2019?

Use the schedule builder feature on the DrupalCon website to build a DrupalCon Seattle schedule for yourself of sessions you want to be sure to catch. Don’t forget to look at the Birds of a Feather events, which tend to be smaller and more informal. And don’t schedule yourself so tight that you miss out on the hallway track. My most interesting conversations at DrupalCon usually happen in the hallways and at evening social events.
 

How would you characterize Drupal’s position today within the world of web content management platforms?

Drupal is an enterprise-level content management platform that delivers much of the functionality you would expect from some of the million dollar proprietary CMS platforms, while still retaining the freedom and flexibility inherent in its open-source roots.
 

What are your thoughts on when, why or how Drupal has achieved this status?

I think it was a coordinated effort related to the Drupal 8 rollout. D8 was a total rewrite of the CMS, with the goal of producing an enterprise-grade CMS that would be on par with the established and expensive proprietary platforms. The momentum is now really strong for Drupal as an enterprise CMS.

What sets Drupal apart from other web content management platforms?

The freedom, flexibility, and lack of license fees that come with open source set it apart from all the proprietary options. It’s different from any other open-source CMS in that it has strong corporate sponsorship, a dedicated security team, and an enterprise heavy install base.


What will the extent of your participation in DrupalCon Seattle?

I’m excited about attending the GovSummit on Monday, April 8, and will be presenting in the Builder Track at 3:15 on Wednesday, April 10, in Room 608. Otherwise, I’ll be in and out of sessions and at the Promet Booth (#308) for the rest of the event. This is Promet’s 12th year as an attendee and 11th year as a sponsor. Once again, we’ll be all over DrupalCon. The entire senior leadership team will be there, along with some of our senior developers and our entire sales and marketing team. I’m particularly excited about the addition of Mindy League to our leadership team this year. The Human Centered Design team that she is heading represents an exciting expansion for Promet. I definitely recommend that anyone who is interested in the very latest in design thinking for digital experiences make it a point to grab some time with Mindy. 


How would you characterize Promet’s client base for whom Drupal proves to be the right solution?

Very much in line with what Dries Buytaert, the founder of Drupal said at DrupalCon two years ago: “Drupal is for organizations that are looking to build ambitious digital experiences.” It’s not so much about the size of the company or the team, it’s about the reach and impact that the site needs to have. 

The fact is, I spend very little time selling Drupal websites. I sell e-commerce solutions that will generate more revenue. I sell accessibility, more streamlined user experiences, sites that are better targeted to the needs of customers, and sites that more effectively reflect an organization brand image.

Be sure to stop by booth #308 at Drupalcon in Seattle, April 8-12 to visit with us, or Contact us today for a conversation about how Promet can create an ambitious digital experience for your organization. 

Photo credit: Michael Cannon

<

Mar 19 2019
Mar 19

Drupal 8.6 became one of the most interesting releases in Drupal 8’s history. It brought us the oEmbed feature, the Media Library, the Workspaces module, and more. But it’s time to move forward, and in May 2019 we expect Drupal 8.7. Its “alpha” version has just been released. Although an alpha version is not the final one, we will gladly take a look at it and discuss what to expect in Drupal 8.7.

Drupal 8.7: the alpha version

Drupal 8.7.0-alpha1 came out on March 14, 2019. Alpha versions are far from being ready for production sites. They are just preliminary releases that allow developers to do a good testing, receive feedback, make final preparations, and fix bugs.

After the “alpha,” we are supposed to see the “beta” version of Drupal 8.7 in the week of March 25. Next, the RC (release candidate) phase will begin in mid April.

When everything is tested thoroughly and polished to perfection, we will enjoy the stable version of Drupal 8.7 on May 1! Let’s see what to expect in Drupal 8.7 now that we are looking at Drupal 8.7.0-alpha1.

Expected features of Drupal 8.7

  • End of support for PHP 5.5 and 5.6

Websites are officially becoming lighter and faster due to the use of PHP 7.1+. Drupal 8.6 was the last release to support PHP 5.5 and PHP 5.6. Drupal 8.7 is definitely the time to say goodbye to these obsolete versions of the programming language.

According to Drupal 8.7 alpha 1 release notes, they will officially stop being supported in Drupal 8.7 beta. So those who are using PHP 5.5 and PHP 5.6 will need to upgrade to PHP 7.1 or higher, and our Drupal support team can help.

  • End of support for Internet Explorer 9

The support for Internet Explorer 9 and 10 was stopped back in Drupal 8.4. However, there was a workaround left in Drupal 8.5 and Drupal 8.6 that allowed 32+ stylesheets to be included.

Drupal 8.7 has now officially removed this workaround, so goodbye to Internet Explorer 9. Those who rely on it will need to enable CSS aggregation or install the IE9 Compatibility Drupal module.

  • No more automatic entity updates

As of Drupal 8.7, automatic entity updates are no longer supported by Drupal core. This is meant to avoid conflicts and preserve data integrity. For updating the entities, the Update API should be used. In addition, the drush entity-update (drush entup) command is also not supported anymore. 

  • New UI for the Media Library module

The Media Library module lets you save various multimedia and use them in your content to make it more engaging. It’s possible to embed multimedia directly into content types using the “media” field.

The Media Library works together with the Media module that is already stable. Stable Media Library was first scheduled for Drupal 8.7 but we are likely to see it in Drupal 8.8 after a number of fixes and WYSIWYG support added. 

However, we can enjoy a new and interesting Media Library admin interface in Drupal 8.7. Its features have mostly made it to Drupal 8.7.0 alpha 1 but the completed UI will be available soon in alpha 2 or beta 1.

New Media Library admin UI for Drupal 8.7New Media Library admin UI for Drupal 8.7
  • Adding JSON:API to Drupal 8 core

The JSON:API contributed module is meant for creating high-performance APIs to expose Drupal data in JSON. It immediately creates API endpoints and requires no configuration. The module instantly accesses all Drupal entities.

According to Drupal development roadmap, JSON:API is meant to join the core in Drupal 8.7. JSON:API will look great in Drupal core’s ecosystem of web services that are responsible for third-party integration.

Joining Drupal core is a serious step for any module, especially for a complex one like JSON:API. There has been a hard work done on fixing the last issues related to adding JSON:API to Drupal 8.7 core, and all are fixed now.

Although we don’t yet see the module in the Drupal 8.7 alpha 1 admin dashboard, we will probably see it in alpha 2 or beta. So congrats to JSON:API! Update for 21/03: JSON:API has just landed in Drupal core!

  • Improvements and stabilization for the Layout Builder 

The Layout Builder module in Drupal 8 core allows you to build layouts like Legos by using ready multi-column layouts and Drupal blocks. 

These can be layouts for content, users, contact forms, and other fieldable entities. You can have a specific layout for a content type (e.g. all articles), for an individual node (e.g. one article), or for a display mode (e.g. article’s teaser).

The module arrived in Drupal 8.5 core marked as “experimental.” For Drupal 8.7, it has received important bug fixes in the area of saving layouts for the default content layouts and individual nodes, saving layout overrides, using layouts for different display modes, and more. CSS classes have also been renamed to meet the BEM standards.

Drupal development roadmap has the Layout Builder moving from experimental to stable in Drupal 8.7. We don’t see this happening yet in Drupal 8.7 alpha 1, but we expect this in the near future. Update for 29/03: Layout Builder has reached stability in Drupal 8.7 core!

Layout Builder in Drupal 8
  • Updates to the Guzzle library

The Guzzle HTTP client library arrived in Drupal 8 to replace the drupal_http_request() function in Drupal 7. It makes the process of communicating with RESTful web services easier.

Guzzle offers a modern way of making HTTP requests. It is extensible with plugins, easy in use, and based on object-oriented architecture.

In Drupal 8.7, Guzzle has been updated from 6.3.0 to 6.3.3 and http_client service has begun to support empty headers. Additional updates are also planned in Drupal 8.7 beta.

  • Changes to the Stable and Classy themes

The Stable or Classy are among the Drupal core themes in addition to Bartik, Seven, and Stark. If your website’ theme has been created as a subtheme of the Stable or Classy themes, you will need to pay attention to their changes in Drupal 8.7.

They are related to JavaScript message template and pagination header CSS ID. Specifically, if your theme overrides the messaging or pagination templates, you will need some manual changes, and our Drupal experts are ready to provide them.

  • Better Symfony 4 and 5 compatibility

Drupal 8 includes Symfony components for more modern and fast web development. Drupal 9 will completely move to the new Symfony 5.

Drupal 8.7 is getting ready for it. It is providing better compatibility with both Symfony 5 and Symfony 4. This includes changes in the Container and TranslatorInterface Symfony components, as well as resolving critical compatibility issues.

Be ready for a smooth update to Drupal 8.7!

So we now know in a nutshell what to expect in Drupal 8.7 that is coming in May 2019. Of course, you can rely on our Drupal team for a smooth update. 

In the meantime, we can help your website prepare for it, if there is a need to:

  1. update to PHP 7.1+
  2. take care of Internet Explorer 9 issues
  3. apply changes to your Stable and Classy subthemes
  4. check the compatibility of any other website components 

Contact our Drupal team!
 

Mar 19 2019
Mar 19

Late last year, we started a series of posts that tell the story of what makes Agiledrop the company that it is today. In the first chapter, we presented our unique workflow, while the second and third chapter dealt with the major challenges that arose from such a workflow and our very efficient solutions to them.

This final chapter of the series will tie things together, diving into our company culture which strongly promotes cooperation and knowledge-sharing. This ensures that our clients always benefit from the collective knowledge and skillsets of the entire Agiledrop team.

Well, let’s get right down to it!

Basing our company culture on cooperation and knowledge-sharing

What makes Agiledrop stand out is our strong culture of support and knowledge-sharing among developers. We make it a priority to integrate new employees into our A-team, make them feel welcome and help them become fully-fledged members of the team as soon as possible. Creating a collaborative and welcoming working environment is the responsibility of every person on the team and something we all participate in. 

The onboarding and mentoring of new developers is a prime example of our company culture - but it doesn’t stop there. We promote and encourage knowledge-sharing between all members of the team, no matter their status within the company or the amount of time spent with us.

Our development leads are always available to help developers weather through any obstacles they might encounter - be they considerable or negligible ones. In this way, we are able to find solutions much faster, which results in fewer working hours spent on a specific issue and, in consequence, significantly lower costs for the client.

We also have a Slack workspace dedicated exclusively to obstacles encountered by developers during their work. Every member of the team participates, no matter their physical location. It’s a place where the real knowledge exchange is allowed to happen. One of the best things to see there is when a newly recruited junior developer who is still dealing with their onboarding project helps out a senior developer with one of their issues - and it happens more often than you’d think!

In short, when working at Agiledrop, you are never given the impression that your lack of knowledge is detrimental to anyone on the team or the company as a whole; rather, it’s an opportunity to learn something new or revisit something already learned. 

Balancing the happiness of clients and developers

It’s not always easy to sustain such a well-defined and inclusive company culture. On the one hand, the development leads in the mentor roles must possess an innate pedagogical capacity in addition to extensive technical knowledge and a knack for spotting and solving problems. On the other hand, however, we must take great care to understand the positions of both the developer and client when a problem arises, and not simply look for scapegoats.

In order to catch and resolve issues in the early stages of a project and not after a month, we do weekly reports every Friday. These reports are done in two directions: our resource manager collects feedback from the clients, while the development director checks the issues that were raised by developers, such as not getting enough tasks or sufficient information to fulfill a task.

Issues raised by the clients are not something we punish; instead, we aim to provide constructive feedback to improve on the mistake, not just sanction it. The development director will speak with developers and suggest any improvements to their work. Likewise, the resource manager will notify the client about issues raised by developers so that they can do certain things differently in the future. 

Such a system ensures constant smooth communication between everyone involved in the projects, making it easier to find solutions and improvements while also keeping each side satisfied and up-to-date on any new projects and developments. 

Boosting morale and keeping the team motivated

We understand that a motivated team is more committed and able to deliver better results. It’s easier for people to give their best and be satisfied with their job when they know that their work makes a difference. The appreciation of their peers and superiors gives them the confidence needed to get through even the most difficult days.

For this reason, we hold weekly meetings every Monday and monthly meetings every first Thursday of the month; these meetings are essentially weekly and monthly reviews where we go through our new and ongoing projects. But, most importantly, they are an opportunity to congratulate people for the good work they’ve been doing, which helps boost the morale of the entire team. 

We also frequently organize various educational and sports activities that bring the whole team together, which results in new friendships and another level of knowledge-exchange. Besides our free Drupal courses where we train wannabe Drupal developers (who often go on to become full members of our team!), we also:

  • Organize TechTalks, which we call AgileTalks, on developers’ own initiative,
  • Attend tech conferences and other Drupal-related events,
  • Promote and reward any additional activities of developers, such as the organization of an aforementioned AgileTalk or writing a blog post on a topic of their choosing,
  • Organize teambuildings,
  • Organize differently-themed common lunches,
  • Enable flexible working hours that ensure a healthy work-life balance for developers.

Additionally, we also collect feedback through Officevibe surveys, which makes for a better overview of the week-to-week satisfaction of our employees and enables us to constantly improve the way we do things. A pleasant working environment and a good team spirit are key to a strong company culture.   

Providing clients with our collective knowledge

Because we base our company culture on collaboration and knowledge-exchange, we are in a unique position where we can offer our clients not just individual, but the collective knowledge of the entire Agiledrop team. By exchanging ideas and sharing resources, we are much more productive and consequently able to provide solutions faster and more efficiently. 

If you’ve read the other posts in this series (and we suggest you do!), you’ll notice that the values outlined in this post are intrinsically tied to and realized in all aspects of the work we do. We take the same understanding and inclusive approach with developers and clients alike, and we believe this is what lies at the heart of our success. 

We truly operate as a team, having each other’s back and valuing the input of each and every member. As a result, we managed to strike the perfect balance between the wants and needs of our clients and developers. This balance guarantees, on the one hand, that our developers work for a company that helps them grow, on projects they can take pride in; and, on the other, it ensures the satisfaction of our clients and helps establish ourselves as trustworthy partners that never fail to deliver.

This is evidenced by our fast, but stable growth: in just one year, we doubled the size of our team, opening offices in a new location in Maribor, with plans for a third Slovenian office this year. In addition to that, we are now taking on a number of new and exciting projects for a wide range of different international clients, making for a stable market share. You can dive into the numbers a little bit more by reading our review of 2018.

(This is not) a conclusion

Last year, we thought “Wow - 2018 really is our year”. But, seeing how it’s only the middle of March and there are already so many exciting things going on and planned for later in the year, we might have to reevaluate our previous assessment. Perhaps 2019 will be our year; besides all the new teammates and exciting projects, there’s also a major change for us on the horizon (keep following our blog posts to find out more about it!).

Or, maybe, it’s not about the year at all. Maybe we’ve arrived at the point where we’ve finally realized our vision - maybe, if we keep following in the footsteps that we’ve set for ourselves, every year will be our year. 

And, hopefully, an insight into how we do things at Agiledrop will help other businesses who are dealing with the same obstacles as we did, giving them proof that, yes, it is possible to start and successfully scale the kind of company you’d be proud working for!

So, this was the story of how we transformed Agiledrop into what it is today - a company one can take pride to work at and work with. We hope this series has given you some ideas on how to kill two birds with one stone by keeping your employees and clients happy. If you’re interested in working with us, give us a shout out!

Other posts in this series:

Mar 19 2019
Mar 19

In preparation for his fourth DrupalCon, Chris O’Donnell, Digital Strategist, for Promet Source shared his views on the vibe of this annual conference, as well as Drupal’s current standing within the ecosystem of enterprise-level CMS platforms.  
 

What are you looking forward to at Drupalcon this year?

One of the best parts of DrupalCon for me is the community. It’s an opportunity to connect with people who I might only get to see once a year -- colleagues from other Drupal development companies, previous clients, current clients, and like-minded people from all over the country. There’s a ton of training and all of the sessions are driven by community involvement -- people who are just sharing their knowledge for the fun of it, or as a way to give back to the community.

Last year at DrupalCon, there was a proprietary software company exhibiting for the first time. They seemed really confused by world  where a development company was on the stage with some of its best customers. Why would anyone share great information with potential competitors? They were really confused by the entire thing - competitors coming together to openly share knowledge just didn't compute for them.

How would you explain it?

DrupalCon is more like a Drupal community celebration than a tech industry trade show. 

I think it was President Kennedy who said, “A rising tide lifts all boats,” and the same principle applies within the Drupal Community, or any open source community. The more brain power that goes into it, the better it is for everybody. As an open-source CMS, the Drupal community is driven by the community and the needs of users. Anything that anyone does to improve or add to Drupal is freely available to all. 

I joined the Drupal community in 2014, and I love being among hundreds of thousands of people around the world who contribute to the community in various ways. 


What are your observations on how DrupalCon has evolved?

There has been a pretty big shift this year as the Con has been organized around specific tracks. Drupal 8 ushered in an orientation toward more of an enterprise-level focus, and that’s been reflected in the kind of training that’s offered and an expanded sphere of people who are attending.

With so much going on, what's your advice for attendees for getting the most out of DrupalCon?

Use the schedule builder feature on the DrupalCon website to build yourself a schedule of sessions you want to be sure to catch. Don’t forget to look at the Birds of a Feather events, which tend to be smaller and more informal. However, don’t schedule yourself so tight that you miss out on the hallway track. My most interesting conversations at DrupalCon usually happen in the hallways and at evening social events.
 

How would you characterize Drupal’s position today within the world of web content management platforms?

Drupal is an enterprise-level content management platform that delivers much of the functionality you would expect from some of the million dollar proprietary CMS platforms, while still retaining the freedom and flexibility inherent in its open-source roots.
 

What are your thoughts on when, why or how Drupal has achieved this status?

I think it was a coordinated effort related to the Drupal 8 rollout. D8 was a total rewrite of the CMS, with the goal of producing an enterprise-grade CMS that would be on par with the established and expensive proprietary platforms. The momentum is now really strong for Drupal as an enterprise CMS.

What sets Drupal apart from other web content management platforms?

The freedom, flexibility, and lack of license fees that come with open source set it apart from all the proprietary options. It’s different from any other open-source CMS in that it has strong corporate sponsorship, a dedicated security team, and an enterprise heavy install base.


What will the extent of your participation in DrupalCon be this year?

I’m excited about attending the GovSummit on Monday, April 8, and will be presenting in the Builder Track at 3:15 on Wednesday, April 10, in Room 608. Otherwise, I’ll be in and out of sessions and at the Promet Booth (#308) for the rest of the event. This is Promet’s 12th year as an attendee and 11th year as a sponsor. Once again, we’ll be all over DrupalCon. The entire senior leadership team will be there, along with some of our senior developers and our entire sales and marketing team. I’m particularly excited about the addition of Mindy League to our leadership team this year. The Human Centered Design team that she is heading represents an exciting expansion for Promet. I definitely recommend that anyone who is interested in the very latest in design thinking for digital experiences make it a point to grab some time with Mindy. 


How would you characterize Promet’s client base for whom Drupal proves to be the right solution?

Very much in line with what Dries Buytaert, the founder of Drupal said at DrupalCon twy years ago: “Drupal is for organizations that are looking to build ambitious digital experiences.” It’s not so much about the size of the company or the team, it’s about the reach and impact that the site needs to have. 

The fact is, I spend very little time selling Drupal websites. I sell e-commerce solutions that will generate more revenue. I sell accessibility, more streamlined user experiences, sites that are better targeted to the needs of customers, and sites that more effectively reflect an organization brand image.

Stop by booth #308 at Drupalcon in Seattle, April 8-12, or Contact Us Today for a conversation about how Promet can create an ambitious digital experience for your organization. 
 

<

Mar 18 2019
Mar 18

We’re featuring some of the people in the Drupalverse! This Q&A series highlights individuals you could meet at DrupalCon.

Every year, DrupalCon is the largest gathering of people who belong to this community. To celebrate and take note of what DrupalCon means to them, we’re featuring an array of perspectives and fun facts to help you get to know your community.
 

Mar 18 2019
Mar 18

Problem

How do you migrate webforms and submissions from previous versions of Drupal and other form builders?

The answer is Drupal's Migrate API, which is incredibly powerful but can feel overwhelming. When I migrated MSKCC.org from Drupal 6 to Drupal 8, the Migrate API was just being introduced into Drupal 8 core, and I felt more comfortable writing a custom migration script instead of using code that was still under development. Migrate API is now stable and if you are an experienced Drupal developer, you should use it.

Certain aspects of Drupal require some expertise.

The level of expertise required to build and maintain a Drupal 8 website has changed from Drupal 7, mainly because we are creating more ambitious digital experiences. The Drupal community struggles to simplify our flexible and sometimes complex product. My approach is to make the Webform module as flexible and robust as possible, while not forgetting that people need a simple way to start building a form. This is exactly why I include an introduction video on the Webform module's main page. Besides making the Webform module an awesome tool for experienced Drupal site builders, the Webform module needs to be welcoming to new users and make it easy for them to move their existing forms to Drupal.

Either an organization is starting from scratch and building a new Drupal site, or more commonly an organization has decided they need to provide a more ambitious digital experience and they have chosen to switch to Drupal. In both situations, we need to make it easy for someone to switch from other form builders to Webform.

The problem that needs to be addressed is…

How can we make it easy for an organization to migrate existing forms with submissions to the Webform module?

Solution

The simplest way to migrate to the Webform module is to rebuild an external form and then import the existing data. Building a webform is fun and easy, forms are a critical aspect to most websites; it is worth taking the time needed to rebuild an existing form, and take full advantage of all the cool elements and features available in the Webform module. The only missing feature from the Webform module is an easy and fast way to import existing submission data.

The Webform module already makes it easy to export submissions. There is a 'Download' tab under the Results section that generates a CSV (comma separated values) which can be opened in Excel or Google Sheets.

The solution is to make it extremely easy for anyone to import submissions using a CSV.

Importing a CSV containing submission data should be a simple process where a site builder uploads a CSV, which is prepared, reviewed, validated, and submitted to a webform.

Below are the steps which one might take to import CSV data:

  • Build a webform
  • Populate webform with some test submissions
  • Download the test submissions using the CSV export
  • Examine the CSV export
  • Populate the CSV export with external data
  • Upload and import the CSV export
  • Review imported data

Being able to export and import submission data as needed has the added bonus that site builders can download all the existing submissions, bulk edit them using Excel or Google Sheets, and then upload them back into the database. Submissions can now be migrated from one server to another. There is only one caveat, and it is not required, but it helps to make sure all exported and imported CSV records have a UUID (universally unique identifier).

Notes

The below notes are pulled directly for the Webform module's CSV upload form:

  • All submission properties and data is optional.
  • If UUIDs are included, existing submissions will always be updated.
  • If UUIDs are not included, already imported and unchanged records will not create duplication submissions.
  • File uploads must use publicly access URLs which begin with http:// or https://.
  • Entity references can use UUIDs or entity IDs.
  • Composite (single) values are annotated using double underscores. (e.g. ELEMENT_KEY__SUB_ELEMENT_KEY)
  • Multiple values are comma delimited with any nested commas URI escaped (%2E).
  • Multiple composite values are formatted using inline YAML.
  • Import maximum execution time limit is 6 hours.

For those hardcore developers out there, the answer is…

Yes!!! There is even a drush:webform:import command.

Demo

To make sure no one feels overwhelmed, I created the below video to help people feel more comfortable with this new functionality.

Supporting organization

This awesome new feature was sponsored by Kennesaw State University. Kaleem Clarkson (kclarkson), Operations Manager @ Center for Excellence in Teaching & Learning at Kennesaw State University, and I scoped out this ticket on Drupal.org via Issue #2902977: Provide a straight forward tool for importing submissions from a CSV document.

I previously talked about Coming to an agreement within the Drupal community and sponsoring a Webform feature, and it is challenging working out the process for a paid feature. I have discovered that scoping out all paid Webform feature requests on the Drupal.org has worked out to be the most transparent process. Even when a potentially sponsored feature agreement falls through, the scoped out work remains in the Webform issues queue. I feel better knowing the research and work I did for the feature request is not a complete loss. I have even seen a feature request sit in the queue for a few months and then someone like Michael Feranda (mferanda) appears out of nowhere and helps complete a feature like Issue #2888862: Provide a mechanism to lock a webform submission.

Getting Involved

Kaleem Clarkson (kclarkson) and Michael Feranda (mferanda) contributions show there are multiple ways to get involved in helping to support the Webform module and Drupal. Michael found a task in the Webform issue queue and started contributing code back to the Drupal community. Kaleem is not a coder, he is more of a 'master' site builder and community leader, so he found a requirement from his project, convinced Kennesaw State University about the value of contributing back to the Drupal, and they sponsored a pretty awesome improvement, which helps everyone who is adopting the Webform module and Drupal.

Sponsor a Feature

Sponsored a feature is a challenging but needed enhancement to the process of building and maintaining the Webform module. I have had some success implementing a few paid features.

Open Collective provides a transparent platform that might make 'Sponsor a feature' more natural and accessible for the Drupal community. Paying for a feature using Open Collective's payment system which provides standardized invoices could make it easier and justifiable for large organizations to financially contribute to Webform, Drupal, and Open Source.

At the same time, I still feel it is also okay to not pay Open Collective's 13-14% overhead and execute a paid feature request via a direct transaction. Either way, I am absolutely committed to scoping out all feature requests transparently on Drupal.org.

If you have a features request, please create a ticket in the Webform module's issue queue.

Backing the Webform module

Open Collective is providing us, Drupal and Open Source, with a platform to experiment and improve Open Source sustainability. If you appreciate and value what you are getting from the Webform module, please consider becoming a backer of the Webform module's Open Collective.

Become a Backer

Almost done…

We just sent you an email. Please click the link in the email to confirm your subscription!

OKSubscriptions powered by Strikingly

Mar 18 2019
Mar 18

The opening talk as DrupalCamp Paris 2019 was a presentation given by Thomas Jolliet (FranceTV) and yours truly about how we rebuilt FranceTV Sport to a Symfony 4 / headless Drupal 8 combo.

The most salient points of the talk are probably the "defense in depth" mechanisms we built for scalability and fault tolerance, and the business results, like -85% full page load time or +50 iOS users.

Mar 18 2019
Mar 18

The opening talk as DrupalCamp Paris 2019 was a presentation given by Thomas Jolliet (FranceTV) and yours truly about how we rebuilt FranceTV Sport to a Symfony 4 / headless Drupal 8 combo.

The most salient points of the talk are probably the "defense in depth" mechanisms we built for scalability and fault tolerance, and the business results, like -85% full page load time, -65% speed index, or +50% iOS app traffic.

Mar 18 2019
Mar 18

At Third & Grove, we believe that Drupal is the best technology for most projects (here are 15 things Drupal can do to beat or achieve parity with AEM), but there are three use cases where AEM is likely a better fit:

  1. Institutional investment in the Java programming language. If your organization has decided that Java is the only programming language you’ll use, then AEM is likely a better fit for you. Standardizing the programming language has many drawbacks, but just as many benefits. By focusing on one language, you have an elastic resource pool within your organization that will allow you to move engineers between projects as needed, a single hiring pipeline of Java talent to draw from, and, likely, Java contractors who are ready to be mercenaries no matter the theater of war.

  2. Campaign management. While Drupal can be used successfully in any campaign effort, AEM has superior support for robust, large-scale, complex campaigns. If your organization operates campaigns at high levels of complexity, AEM is likely a better choice than Drupal.

  3. Integration with other Adobe tools. If your organization has already invested in other Adobe technologies, you may find institutional approval for deploying AEM is easier than Drupal, despite Drupal’s established compatibility with Adobe’s toolset. As an example, Adobe has a great stock photo management tool that is part of their Creative Cloud. Not only does Adobe Stock integrate well with Creative Cloud, but as an Adobe product, it also integrates seamlessly with Adobe Experience Manager, a completely different product set than Creative Cloud.

Conversely, if time to market, cost, the value of open source, and security are priority concerns at your organization, Drupal is likely to be more successful than AEM.

Drupal’s robust open source ecosystem of free system extensions and generally less-complex technical footprint result in lower levels of effort, which decreases cost, improves time to market, and reduces overall risk. A combination of more people, with fewer conflicts of interest, working to improve the core Drupal software in a culture of security prioritization generally means Drupal is the more secure, better-supported platform.

Budget and ROI

The primary total cost of implementation between AEM and Drupal is largely impacted by three factors:

  1. Licensing fees

  2. General platform technical complexity

  3. The extension ecosystem

A typical enterprise Acquia Drupal project would usually have an implementation budget of $250,000-$350,000, while an AEM budget would start north of $500,000 (and that isn’t including the licensing fee you need to pay Adobe). When you add hosting, the first year total spend for an organization to redesign, build, and host an enterprise Acquia Drupal site is likely around $500,000 while in AEM you are looking at $750,000-$1 million.

AEM often describes Drupal’s open source status as free like a puppy—meaning Drupal is free, but it takes a terrific amount of work to build into a compelling digital platform. This is partly true, in that Drupal is more a content management framework (as opposed to a content management system), and can thus be adapted to address many use cases. But so is AEM.

Savings for picking Drupal over AEM come not just from a lack of licensing fees but also from Drupal’s open source community, which has promoted a far more extensive network of free extensions that add functionality to Drupal. AEM’s extension ecosystem is far smaller, and thus less impactful when it comes to accelerating website build efforts.

While AEM and Drupal have robust internal technical architectures that can scale to meet the digital demands of most organizations, the general consensus is that the “technical weight” of AEM is heavier, and thus builds are slower. At Third & Grove, we have seen this first-hand when working with a publicly-traded client with billions in revenue. We created a stir by migrating one of this company’s brand sites to Drupal in less than two months. The internal mandate from the global CTO was to use AEM, but the AEM team needed nine months for the migration we achieved in just six weeks.

Return on investment (ROI) is a different matter. Drupal’s generally smaller implementation budgets mean more value has to be derived from a comparable AEM site to achieve the same ROI. Out of the gate, Drupal has an unfair advantage. Still, the reality of digital technology investment is that when you are choosing between the two or three top platforms in any problem space (in this case, the digital experience space) the value you derive has little to do with the platform you choose and everything to do with how effective it is in helping achieve institutional goals. The reality of IT—that it is simultaneously as critical to the business’s success as it is irrelevant to the business strategy—is just as true for digital investments.

What Your Team Will Think

Your team’s opinion will depend largely on which platform you choose and, often most critically, their past experiences with the platform. One would hope that your team would embrace the platform that best serves the myriad needs of your organization, the overall strategy, IT goals, and marketing goals. However, the reality is that your team’s acceptance of the editorial experience of both platforms by is going to be driven mostly by factors unrelated to the platforms themselves. Instead, it’s more driven by past experiences, job frustrations, and a culture of blame (should one exist).

We’ve worked with many enterprise teams that leverage Acquia Drupal. Here’s what we’ve noticed from working with them:

  • Engineering. Your engineering team may complain about having to write PHP, which they may view as an inferior programming language. (See our article on misconceptions on Drupal for more information on why this assessment is based on years-old information.) If your engineering team already embraces open source solutions, they will be excited by all the open source components that make Drupal great. Moreover, an engineering team with a culture of learning will thrive in the developer-centric ecosystem that uniquely defines Drupal in the CMS space.

  • Marketing. Your marketing team might be anxious about the page-building experience. Older versions of Drupal offered an inferior page-building experience to AEM, which may be the source of this platform anxiety. We have watched many marketers become excited to use a platform with high developer velocity, because that, in turn, allows them to become agile marketers.

And here’s what you might expect if you adopt AEM:

  • Engineering. Your engineering team will probably be excited to use Java, an enterprise-grade programming language with a reputation for scale and stability that is used widely among large companies. But there are drawbacks that will hurt any engineer. The AEM platform requires technical debt to achieve scale and develop integrations. Not least, there is no AEM equivalent of Drupal’s open-source modules, which can elevate a digital experience—or at least remove the pain of resolving problems that have already been solved.

  • Marketing. If we had to guess, your marketing team would likely be impressed by AEM’s slick page-building experience and seamless integration with Adobe tools like Analytics. Even though they will have better resources they might be concerned about the reduced developer velocity in adding new features and making site changes. Agile marketing is the goal of every cutting-edge marketing team, and often a point of frustration as teams try to grow.

Organizations can reduce resistance by working to align the true needs of individual marketing team members to the goals of the marketing organization and the business overall. Both AEM and Drupal can be implemented to make your team feel like they are being set up for success—or failure; the deciding factor is effort.

Evaluation Chart for AEM vs. Drupal

To us, there are four main considerations in choosing AEM vs. Drupal: cost, time to market, cloud platform, and campaign management. We’ve outlined all considerations that we go through with our clients, which help identify an objective decision.

Consideration

Adobe Experience Manager

Acquia Drupal

Cost

-1

AEM requires a licensing fee and often higher implementation budgets than Drupal

+1

Drupal is free to use and implementation budgets are generally lower

Time to market

-1

+1

Since implementation budgets are generally lower than AEM, time to market is generally faster

Fully managed outsourced cloud platform

+/- 0

Adobe now has a cloud platform for AEM, but the platform is just over a year old

+1

Acquia is the enterprise cloud platform for Drupal and is more than ten years old, so their platform is mature, battle-tested, and feature rich

Campaign management

+1

AEM leads for complex, robust campaign management needs

+/- 0

Drupal can power complex customer journeys, but support is not as seamless as it is for AEM. Acquia’s new Journey software is likely to improve support dramatically

Institutional investment in Java resources and the desire to stay within Java

+1

+/- 0

Institutional investment in PHP resources and the desire to stay within PHP

+/- 0

+1

Open source solutions are valued for their scalability, security, transparency, and community value

+/- 0

AEM is closed source and only Adobe employees can enhance the software

+1

Drupal is open source, and benefits from thousands of developers in the community making the product better every day

Large, complex site with many integrations

+1

AEM runs large, complex sites for major organizations like Delta.com and Salesforce.com

+1

Drupal runs large, complex sites for major organizations like Wendy's.com, Weather.com, and FEMA

Integration with Adobe products like Creative Cloud, Adobe Analytics, Test & Target

+1

AEM integrates well with its own marketing cloud products

-1

Acquia Drupal can integrate with many of the Adobe tools, but nothing beats native integration

Asset management

+1

AEM has slick support for asset management

+/- 0

Acquia Drupal has strong support for asset management, but AEM tends to be better executed out-of-the-box

Running multiple websites, large and small

+1

AEM has strong support for running multiple websites

+1

Acquia Drupal, especially using Acquia Site Factory, has strong support for running multiple websites

Custom reporting capabilities

+1

AEM has many good reports available out-of-the-box

+1

Acquia Drupal provides the powerful Views module (built into Drupal core) that allows non-technical users to use an intuitive GUI to make powerful custom reports for all kinds of data in the system

At the end of the day, it’s not about the best platform—it’s about the right tool for the job. Just make sure that the tool you pick will still be relevant for years to come, otherwise, you’re going to be kicking yourself down the road.

Mar 17 2019
Mar 17

Ryan Price, Principal Engineer, Drupal and Web with Autodesk joins Mike Anello to discuss the hurdles involved with implementing a continuous integration system, OpenDevShop, improving hook_help(), a Drupal 8 Feeds-like module, and DrupalCon Seattle!

Interview

DrupalEasy News

Upcoming events

Sponsors

  • Drupal Aid - Drupal support and maintenance services. Get unlimited support, monthly maintenance, and unlimited small jobs starting at $99/mo.
  • WebEnabled.com - devPanel.

Follow us on Twitter

Subscribe

Subscribe to our podcast on iTunes, Google Play or Miro. Listen to our podcast on Stitcher.

If you'd like to leave us a voicemail, call 321-396-2340. Please keep in mind that we might play your voicemail during one of our future podcasts. Feel free to call in with suggestions, rants, questions, or corrections. If you'd rather just send us an email, please use our contact page.

Mar 16 2019
Mar 16

Drush 9 has removed dynamic site aliases. Site aliases are hardcoded in YAML files rather than declared in PHP. Sadly, that means that many tricks you could do with the declaration of the site aliases are no longer available.

The only grouping possible is based on the YAML filename. So for example, with the Acquia Cloud Site Factory site aliases generated by the 'blt recipes:aliases:init:acquia' command, you can run a command on the same site across different environments.

But what you can't do is run a command on all the sites in one environment.

One use case for this is checking whether a module is enabled on any sites, so you know that it's safe to remove it from the codebase.

Currently, this is quite a laborious process, as 'drush pm-list' needs to be run for each site.

With environment aliases, this would be a one liner:

drush @hypothetical-env-alias pm-list | ag some_module

('ag' is the very useful silver searcher unix command, which is almost the same as the also excellent 'ack' but faster, and both are much better than grep.)

While site aliases are fixed, they can be altered with Drush hooks. I considered that these might allow something to dynamically declare aliases, or a command option. There's an example of altering aliases with a hook in the Drush code.

In the meantime, a much simpler solution is to use xargs, which I have recently found is extremely useful in all sorts of situations. Because this allows you to run one command multiple times with a set of parameters, all you need to do is pass it a list of site aliases. Fortunately, the 'drush sa' command has lots of formatting options, and one of them gives us just what we need, a list of aliases with one on each line:

drush sa --format=list 

That gives us all the aliases, and we probably don't want that. So here's where ag first comes in to play, as we can filter the list, for example, to only run on live sites (I'm using my ACSF aliases here as an example):

drush sa --format=list| ag 01live

Now we have a filtered list of aliases, and we can feed that into xargs:

drush sa --format=list| ag 01live | xargs -I % drush % pm-list

Normally, xargs puts the input parameter at the end of its command, but here we want it inserted just after the 'drush' command. The -I parameter allows us to specify a placeholder where the input parameter goes, so:

xargs -I % drush % pm-list

says that we want the site name to go where the '%' is, and means that that xargs will run:

drush SITE-ALIAS pm-list

with each value it receives, in this case, each site alias.

Another thing we will do with xargs is set the -t parameter, which outputs each actual command it executes on STDERR. That acts as a heading in the output, so we can clearly see which site is outputting what.

Finally, we can use ag a second time to filter the module list down to just the module we want to find out about:

drush sa --format=list | ag live | xargs -t -I % drush % pml | ag some_module 

The nice thing about the -t parameter is that as it's STDERR, it's not affected by the final pipe to ag for filtering output. So the output will consist of the drush command for the site, followed by the filtered output.

And hey presto.

In conclusion: dynamic site aliases in Drush were nice, but the maintainers removed them (as far as I can gather) because they were a mess to implement, and removing them vastly simplified things. Doing the equivalent with xargs took a bit of figuring out, but once you know how to do it, it's actually a much more powerful way to work with multiple sites at once.

Mar 16 2019
Mar 16

Planning to build a social network with Drupal? A business community maybe? A team or department collaborating on an intranet or portal? Or a network grouping multiple registered users that should be able to create and edit their own content and share their knowledge? What are those key Drupal 8 modules that would help you get started?

That would help you lay the groundwork...

And there are lots of social networking apps in Drupal core and powerful third-party modules that you could leverage, but first you need to set up your essential kit.

To give you a hand with that, we've selected:

5 modules in Drupal 8, plus a Drupal distribution, that you'll need to start a perfectly functional social networking website, with all the must-have content management features and knowledge sharing tools.
 

Before You Get Started: A Few Things to Take Care Of

First of all, let me guess the features on your must-have list:
 

  • articles
  • groups
  • photos
  • user profiles
  • groups
  • forums
     

It should feature pages with dynamic content leveraging a fine-grained access system and social media hubs, right?

Well, now that we've agreed on this, here are the preliminary steps to take before you get actually started, installing your key modules and so on:
 

  • configure your “Taxonomy” categories after you've installed the Forum module
  • set up a custom content type for Blog posts 
  • set up your thumbnail settings for the Article nodes
  • create your key user roles (admin, content author, paid subscriptions)
  • use the PathAuto module to define your URL path structure
  • define your Article nodes' thumbnail settings and remember to upload an anchor image, as well
     

Panels and Views make a “power team” to rely on for setting up pages with dynamic content for your social networking site.

What makes it a must-have module to add to your essential kit when you build a social network with Drupal? 

It enables you to create custom layouts for multiple uses.

You get to use it to set up your website's homepage, one featuring multiple Views blocks with dynamic content retrieved from forums, articles, blogs...

Feel free to add a top slideshow image, to go for multiple-tiled stacked layout, including views from forum, blog and article posts...

In short: the Panels module empowers you to get as creative as possible when setting up fine-tuned layouts for your landing pages displaying dynamic content.
 

Not only that it enables you to present content to your social network's registered users in pretty much any form you might think of — tables, lists, blocks, forum posts, galleries, reports, graphs — but it also:
 

  • enables you to display related content (e.g. display a list of the community members along with their pieces of content)
  • enables you to use contextual filters
     

It'll turn out to be one of the handiest Drupal 8 modules in your toolbox when you need to create and display dynamic content from:
 

  • forums
  • blocks
  • blogs
     

Yet, maybe one of the most common use cases for the Views module on a social networking website is that of:

Setting up a (Views) page listing all the article posts.
 

Another module you'll most certainly want to add to your social networking website as it:
 

  • enables both single and multi-user blogs
  • empowers authorized site members to maintain it
     

Speaking of which, blog entries can be either public or private for a specific user, depending on the role he/she's assigned with.

And it's precisely that system of user roles and corresponding permissions set up on your website that will determine whether a member can:
 

  • access the “Create Content” link or not
  • access a “My Blog” section or... not
     

You can further leverage this Blog module to add a “Recent blog posts” block to your webpages, in addition to the “Blogs” navigation link on your main navigation menu.
 

4. Profile, a Must-Have Module to Build a Social Network with Drupal

You just imagine that you could build a social network with Drupal without a module enabling you to create registration page fields, now can you?

Well, here it is: the Profile module.

And here are its “superpowers”:
 

  • it enables configurable user profiles
  • it enables expanded fields on the user registration page
  • it provides social network members with two different links, one for their account settings, one for their user profiles
  • it provides private profile fields (that only the admin and that specific user can access)
  • it enables you to set up different profile types for different user roles with... different permissions granted 
     

The sky is the limit in terms of what the Group module enables you to do when you build a social network with Drupal:
 

  • it powers pretty much any scenario you can think of, from subgroups to specific per-group behavior, to access permissions...
  • it enables you to put together content collections on your website and grant access to it based on your user roles and permissions policy
  • it enables you to easily add relevant metadata to define the group & content relationships on your site
  • it enables you to control all your settings via a user-friendly admin UI; no need to write custom code to determine what each group is allowed and not allowed to do on your social network
     

I just couldn't help it...

Even though this was supposed to be a roundup of those essential modules you'll need to build a social network with Drupal, I had to add this Drupal distribution, as well.

Open Social is that out-of-the-box solution that you can leverage to get your online user community up and running in no time.

An open source software with all the needed features and functionality already pre-built, so that you can enable members on your network to:
 

  • work together
  • share knowledge
  • organize events
     

Convenience at its best when you want to start a social networking website without worrying much about:
 

  • installing a whole collection of modules
  • doing custom work in the “backstage”. 
     

The END!

This is the minimal kit you'll need to build your online community website with Drupal.

Would you have added other essential modules to the list?

Mar 15 2019
Mar 15

The business world is competitive by nature. An organization’s intellectual property and the custom software that costs valuable time and money to develop is an incredibly prized possession - one that’s important to protect. That’s why the idea of procuring an open source solution (free software that can be used by anyone) can be such a foreign and challenging concept for many in the business world.

In this article, we’ll walk through some of the most common questions that clients have about procuring open source software, so that you’ll understand how this software is licensed, what you can and can't do with it, and hopefully help you make an informed decision about procuring and extending open source software services.

How does open source licensing work, exactly?

Open source software turns the traditional software licensing model on its head by allowing users to modify and freely redistribute software. Open source is defined by criteria intended to promote and protect software freedom, and support the communities which contribute to the success of open source projects.

Are there any laws that prevent someone from making changes to the software and repackaging the entire thing for sale?

Many open source projects are able to survive and thrive because there are protections in place that prevent someone from turning the project into something proprietary. Drupal and many other open source projects are covered under the GNU Public License or GPL, one of the most common open source licenses. The GPL prevents anyone from distributing the software that it covers without also sharing its source code. This ensures that the project covered by the GPL remains open source.

Does this mean that if I pay a contractor for custom code to be developed that adds to an existing GPL-covered open source project, I’ll be required to release that work to the public for free?

The short answer is simply “no”. If you work on or pay for someone to work on custom code that modifies a GPL-covered open source project, you won’t be required to give that work away to the community at large.

The GPL only requires that you release your source code if you plan to sell or release (“distribute”) your custom code. If you’re just planning to use the code internally, or as part of a hosted solution that you control, there’s no need to share it with the world.

But shouldn’t I share the code? Isn’t that how open source works?

Many users of open source software do decide to share their source code with the world through contributions to the open source project in question, such as a contributed module in Drupal. There is no requirement to do this, but there are some advantages.

Source code is the actual text document that a software developer creates. It’s uncompiled, meaning that it’s written in programming language that can be read and edited by a human. The reason that distinction is important here is that source code is raw and can be inspected and modified. This practice helps improve both the security and the usability of the software.

By sharing your source code, other people may decide to improve on it and fix it for free, because it’s mutually beneficial. It’s much harder to staff a team of internal developers to keep your code tested, maintained, and bug-free while planning an improvement roadmap to add new features and create new software integrations. Having others work on your code means it is made better both for you and for them. Sometimes the advantage of having software that works really well and has updates and features added more quickly outweighs the advantage of keeping your innovation secret from your competitors.

Curious if open source software is right for your business? Read our post on how you can save money using open source technologies.

Mar 15 2019
Mar 15

Keynote: Learning @ Work

Join Palantir's CEO, Tiffany Farriss, for the keynote at this year's DrupalCorn Camp. With tech still struggling to achieve its diversity and inclusion goals and average job tenure down to less than 3 years, we need to transform how we think about our organizational cultures.

How do we create environments that succeed because of the teams, but where that success is not dependent on any one person? How do we align the company and individual interests so that everyone benefits from however much time that they work together? This presentation explores the role that culture and learning have for organizations and individuals as they work to answering those questions.

  • Date: Friday, September 28, 2018
  • Time: 9:00am
  • Location: Gym - lecture room 2nd floor

Update: Recording of this session is now available on Drupal.tv

Mar 15 2019
Mar 15

With the announcement that the Google Search Appliance was End of Life, many universities started looking around for replacement options. At Palantir, we wanted to provide an open source option that could solve the following needs:

  • A simple way to store, retrieve, and parse content.
  • A cross-platform search application.
  • A speedy, usable, responsive front-end.
  • A flexible, extensible, reusable model.
  • A drop-in replacement for deprecated Google Products

Working with the University of Michigan, we architected and developed a solution. Join Ken Rickard to learn more about Federated Search and to see a live demo.

  • Date: Saturday, February 16
  • Time: 11:00am to 11:45am
  • Location: Room 179 

Update: Video of this session is now available on Drupal.tv

Mar 15 2019
Mar 15

Migrations are fraught with unexpected discoveries and issues. Fighting memory issues with particularly long or processing heavy migrations should not be another obstacle to overcome, however, that is often not the case.

For instance, I recently ran into this no matter how high I raised the PHP memory_limit or lowered the --limit flag value.

$ drush migrate:import example_migration --limit=1000

Fatal error: Allowed memory size of 4244635648 bytes exhausted (tried to allocate 45056 bytes) in web/core/lib/Drupal/Core/Database/Statement.php on line 59

Fatal error: Allowed memory size of 4244635648 bytes exhausted (tried to allocate 65536 bytes) in vendor/symfony/http-kernel/Controller/ArgumentResolver/DefaultValueResolver.php on line 23

It should be noted that the --limit flag, while extremely useful, does not reduce the number of rows loaded into memory. It simply limits the number of destination records created. The source data query has no LIMIT statement, and the processRow(Row $row) method in the source plugin class is still called for every row.

Batch Size

This is where query batch size functionality comes in. This functionality is located in \Drupal\migrate\Plugin\migrate\source\SqlBase and allows for the source data query to be performed in batches, effectively using SQL LIMIT statements.

This can be controlled in the source plugin class with via the batchSize property.

/**
 * {@inheritdoc}
 */
protected $batchSize = 1000;

Alternatively, it can be set in the migration yml file with the batch_size property under the source definition.

source:
  batch_size: 10
  plugin: example_migration_source
  key: example_source_db

There are very few references that I could find in existing online documentation. I eventually discovered it via a passing reference in a Drupal.org issue queue discussion.

Once I knew what I was looking for, I went searching for how this worked and discovered several other valuable options in the migration SqlBase class.

\Drupal\migrate\Plugin\migrate\source\SqlBase

/**
 * Sources whose data may be fetched via a database connection.
 *
 * Available configuration keys:
 * - database_state_key: (optional) Name of the state key which contains an
 *   array with database connection information.
 * - key: (optional) The database key name. Defaults to 'migrate'.
 * - target: (optional) The database target name. Defaults to 'default'.
 * - batch_size: (optional) Number of records to fetch from the database during
 *   each batch. If omitted, all records are fetched in a single query.
 * - ignore_map: (optional) Source data is joined to the map table by default to
 *   improve migration performance. If set to TRUE, the map table will not be
 *   joined. Using expressions in the query may result in column aliases in the
 *   JOIN clause which would be invalid SQL. If you run into this, set
 *   ignore_map to TRUE.
 *
 * For other optional configuration keys inherited from the parent class, refer
 * to \Drupal\migrate\Plugin\migrate\source\SourcePluginBase.
 * …
 */
abstract class SqlBase extends SourcePluginBase implements ContainerFactoryPluginInterface, RequirementsInterface {

Migration Limit

Despite the “flaws” of the --limit flag, it still offers us a valuable tool in our effort to mitigate migration memory issues and increase migration speed. My anecdotal evidence from timing responses from the --feedback flag shows a much high migration throughput for the initial items, and a gradually tapering speed as a migration progresses.

I also encountered an issue where the migration memory reclamation process eventually failed and the migration ground to a halt. I was not alone in this issue, MediaCurrent found and documented this issue in their post Memory Management with Migrations in Drupal 8.

Memory usage is 2.57 GB (85% of limit 3.02 GB), reclaiming memory. [warning] Memory usage is now 2.57 GB (85% of limit 3.02 GB), not enough reclaimed, starting new batch [warning] Processed 1007 items (1007 created, 0 updated, 0 failed, 0 ignored) - done with 'nodes_articles' The migration would then cease to continue importing items as if it had finished, while there were still several hundred thousand nodes left to import. Running the import again would produce the same result.

I adapted the approach MediaCurrent showed in their post to work with Drush 9. It solved the memory issue, improved migration throughput, and provided a standardized way to trigger migrations upon deployment or during testing.

The crux of the solution is to repeatedly call drush migrate:import in a loop with a low --limit value to keep the average item processing time lower.

Our updated version of the script is available in a gist.

So the next time you are tasked with an overwhelming migration challenge, you no longer need to worry about memory issues. Now you can stick to focusing on tracking down the source data, processing and mapping it, and all of the other challenges migrations tend to surface.

Mar 15 2019
Mar 15

A lot of effort goes into engaging your visitors to ‘Sign-up’ or ‘Contact’ you. You send them a warm and fuzzy invitation to complete the form, tell them all the great reasons why they should complete the form… but who likes to complete a form?  Guarantee a smooth sign-up process and increase the completion rate of your webforms with these six tips. 

#1 Make it Flow

Before you begin designing that web form, it is always good to create a User Flowchart. Working to establish the form completion process from start to finish, a flowchart will help you: 

  • Determine what information is needed (and when)
  • Decide what actions and interactions are appropriate
  • Determine the order of actions
  • Make considerations for new patterns to aid the completion process
     

A User Flowchart can begin with a simple Flow Outline, which can then be placed in a flowchart diagram and later illustrated using low fidelity paper prototypes to find the most natural set of actions. When creating the outline consider the following:

The Business Objective

  • What is the main objective of the website for achieving successful completion of the form? (ie, we want to gather as many email addresses as possible.)
  • What is the required information needed from the person completing the form? (ie, we need their name and email, and since our site is only for adults we also need their birth date.)

The User Persona

  • Take advantage of the information gained from the User Personas to focus on the user’s various needs and considerations. What problem do they want to solve and how can this form help them?

  • What devices do they access most frequently to complete webforms? It’s good to know in advance if most of the users complete forms on their mobile phones and/or if they have inferior internet connectivity.

The Entry Point

When designing a User Flowchart, keep in mind the point of entry. Perhaps they arrive after clicking the Call to Action on the homepage. Often webforms are a part of an email or social media campaign, or the user arrives at the form after an organic search. The users should be treated differently based on where they come from, and may need extra context to reiterate the goal of the form to help them get orientated when they arrive. Consider all possibilities.

#2 Keep it Short and Sweet

Don’t ask for information that’s not needed. Your subscription or contact form — or any form that gathers basic information — should only ask for the bare necessities needed in order to accomplish that goal. People will usually stick around long enough to enter their name, email address and password. Anything more than that should be the absolute minimum amount of information needed, with further data obtained in follow-up communications or by implementing a multi-step form (see tip #3). No one enjoys completing a form, so keep it as simple as possible! Neil Patel found that three form fields was the optimal number.  Pegasystems, a Mediacurrent client, leveraged third-party integrations on their Drupal 8 site to pre-fill form fields with data and improved the user experience for returning visitors. 

Reducing the number of form fields can increase conversion rates by 26 percent. 

Email Address

  • Forward thinking email form fields provide suggestions for fixes when the email address has been entered incorrectly. … Did you mean @gmail.com?
  • If you include an auto fix for mistyped email addresses you won’t need to require the user to enter it twice. Otherwise, it’s is a good approach to provide the extra guarantee that they’ve got it right.
  • When the form is for creating an account or signing up for a newsletter, a current practice is to use the email address for the account instead of providing a separate username. This will cause less frustration with creating one that is not already in use, as well as remembering it every time they login.

Name

The person’s name is really only needed in instances where account personalization or custom communication is used. A frequent approach is to provide one field for their full name. This is a bonus since some users may have more than two words that make up their full name, and one field takes less time to complete (especially on mobile devices). Check first to see if the system requires the first name to be isolated for marketing purposes.

Password

  • Enough with the 'confirm password' already! They will lower your conversion rates. Give the user the option to actually SEE the password they’re entering with a ‘show password’ toggle, and they won’t have to enter it twice.
  • Include a Password Strength Indicator. You can get creative with messaging to encourage users to try harder when creating a more secure password like Geeklist does: “Crack Time: 5 minutes”
  • Depending on the level of site security, another time-saving feature is the ability to never have to enter their password again with the ‘Remember Me’ feature.

#3 Multi-step Forms

Single step forms are the most common type of form found on a website. Sometimes, however, using the minimum amount of fields will not accomplish the goal of capturing essential user data. Instead of simply adding more fields to your one-page form you should be aware of an important point: 

Multi-step forms have been found to increase conversions by as much as 300% (without increasing website traffic). 

Multi-step forms convert well for several reasons:

Simplicity

Through the use of progressive disclosure design techniques, we can improve usability when only the minimum data required for a task is presented to the user. Multi-step forms provide the ability to break up a longer form into manageable steps so the user is not visually overwhelmed with requirements at the beginning or during the process. By including only one or two questions per step with a manageable number of steps overall will improve the user experience and significantly increase the chance they will complete it. 

Reduced Psychological Friction

Multi-steps with a simplified interface allow opportunity to use low-friction language in order to reduce psychological friction. In order to encourage the user to become immersed with an energized focus on the activity, we must always seek to minimize disruptions and use language that puts them in a positive state of mind. 

Orientation

Progress bars encourage form completion. The most common use of visual progress trackers are when conducting an online purchase since those are often broken into a multiple step process. It answers the questions the user may have during completion:

  •  How long will the form take?
  • What comes next?
  • Is anything happening?
     

Displaying the steps required to complete the form along with where the user currently is at in the process will help manage their expectations and keep them oriented throughout.

Investment

By using the approach of requesting general information at the beginning of the form and moving towards more sensitive information requests towards the end of the form, the user feels more invested and is therefore more likely to complete.

Conditional Logic

Longer forms will sometimes benefit by using conditional logic in order to personalize the experience. The user is provided with specific questions based on certain responses therefore eliminating irrelevant information retrieval while simultaneously obtaining more targeted data. Save them valuable time and customize their experience, and they will likely reward you by clicking the submit button.

#4 Make it Easy to Read

Including the labels and inputs, consider the context being used for all text on the page and work to ensure your font sizes are large enough to be legible on all devices. The amount of content on the page should be considered while also using best practices for accessibility. 

  • Recent trends are a 14px font size at minimum.
  • When specifying a 16px font size for mobile devices, iOS will not zoom in when the user taps the field, because it’s not needed. This approach can be less distracting especially when there are multiple form fields on the page.
  • Consider the maximum amount of characters that will be needed in all cases to ensure enough room is provided to complete each field. For example, some zip codes in other countries use a varying number of digits.

#5 Inform Everything

Label All Things

The label of the form field you want the user to complete should ALWAYS remain visible. The labels can be placed outside of the field near the top, right, or left — or even better — use the Infield Top Aligned Label. This popular approach has been found to be the quickest to scan, has the best flow, and takes up less real estate. The labels are placed inside of the field, jumping to the top left corner as the user begins typing. Either way, at no point should the user lose sight of the information that’s needed inside of the field.

Inline Form Validation

  • Inform the user as they progress if anything has been entered incorrectly or if a field is missing information. Don’t make them click the ‘Submit’ button at the end of the form only to receive a bunch of red text telling them what they have to re-do.
  • Micro interactions such as a simple green check or a red ‘X’ along with a brief message as the user completes the form will improve the workflow.
  • Tell them if their CAPS LOCK IS ON.

Required or Optional?

Inform the user which fields are required and which are optional for the form to be accepted. An asterisk is often used to designate required information, but they are ignored by screen readers so make sure the required fields include the HTML5 ‘required’ attribute or the aria-required set to true.

Field Details

Explaining the information needed for each field is another great approach. If your Registration Sign-up Form will require a password with at least 6 unique characters with 2 of them numbers, tell them! Does the phone number field require a +, or a country code, or an area code? Tell them or show them.

Progress Bar

  • A form that’s broken into logical steps is easier to complete. If there are multiple steps that require multiple screens to complete, add a progress bar so the user knows where they are in the process.
  • If possible, add a link to the completed steps in the progress bar so the user can go back if needed.

Safety

  • Make your users feel safe during sign-up by informing them about your terms, policies, or rules.
  • Ensure them you will not share their information or spam their email.
  • Provide an easy way to cancel or opt out at any time, without much effort.

#6 Must be Mobile

While optimizing your site for mobile devices, any forms on your site should also be carefully considered. Not only are the screens smaller, but often the connections are slower, and entering text can be a bit tricky, so reducing the number of required fields is especially important. Luckily, recent innovation for mobile forms have provided modern solutions and compression techniques that could actually encourage sign-up on a mobile device:

Predefined DropDowns

  • Whenever possible, avoid open input fields and provide a dropdown list instead for easier completion.
  • Dropdown selections should be written as they would normally display (ie, Credit Card expiry date: 01/20).

Collapsible Menus

This really helps when multiple offerings are available with details for each.

Predictive Search Fields

As the user begins typing the keyword, a list of possible results is provided. 

Calendar Tools

Choose a calendar that is easy to use, with big targets that help to avoid user input errors

Combine Inputs When Possible

Providing only one field for a ‘Full Name’ instead of one for ‘First Name’ and one for ‘Last Name’ will speed up the form completion process and reduce user frustration. 

Automatic Advance

The system should recognize when a date or email has been entered and take the user to the next field automatically, whenever possible.

Buttons That Engage

  • The ‘submit’ button should use a strong command verb that provokes emotion or enthusiasm, such as ‘Sign-Up Now!’
  • Use bright, engaging (and accessible) color combinations. Color changes on tap add even more visual information about the progress.
  • Ensure the tap target is large enough for users with big fingers or who have difficulty being accurate. Apple's iPhone Human Interface Guidelines recommends a minimum target size of 44 pixels wide 44 pixels tall.

Final Word

Achieving a smart form design isn't always easy, but it's well worth the effort. 

What are some great examples of forms you've seen? 

Editor’s note: This post was originally published on November 14, 2016, and has been updated for accuracy and comprehensiveness.

Mar 15 2019
Mar 15

In this post we’ll see how to save temporarily values from a form and how to retrieve or process them later in a controller. To do that, we’ll use the Form API and the private tempstore (the temporary store storage system of Drupal 8).

The use case is the following: we need to build a simple RSS reader (a form) where the user could introduce the URL of an RSS file and the number of items to retrieve from that file.  Next, in a new page (a controller), the application should display the list of items with a link to each syndicated page .

The easiest way to achieve it would be to retrieve the values in our buildForm() method, process them and display the result thought a specific field of the form. But that’s not our use case.

To process the form’s values and to display the results in another page, we’ll first need to store the form's values and retrieve them later in a controller. But how and where to store and retrieve those values?

Long story short: Store and retrieve data with the Private Tempstore System of Drupal 8

Drupal 8 has a powerful key/value system to temporarily store user-specific data and to keep them available between multiple requests even if the user is not logged in. This is the Private Tempstore system.

// 1. Get the private tempstore factory, inject this in your form, controller or service.
$tempstore = \Drupal::service('tempstore.private');
// Get the store collection. 
$store = $tempstore->get('my_module_collection');
// Set the key/value pair.
$store->set('key_name', $value);

// 2. Get the value somewhere else in the app.
$tempstore = \Drupal::service('tempstore.private');
// Get the store collection. 
$store = $tempstore->get('my_module_collection');
// Get the key/value pair.
$value = $store->get('key_name');

// Delete the entry. Not mandatory since the data will be removed after a week.
$store->delete('key_name');

Fairly simple, isn't it? As you can see, the Private Tempstore is a simple key/value pair storage organized with collections (we usually give the name of our module to the collection) to maintain data available temporarily across multiple page requests for a specific user.

Now, that you have the recipe, we can go back to our use case where we are now going to figure out, how and where we could store and retrieve the values of our form.

Long story: Illustrate the Private Tempstore system in Drupal 8

For the long story part, we are going to create a module with a form and a controller to first get the data form the user, store the form’s data in a private tempstore and redirect the form to a controller where we’ll retrieve the data from the tempstore and process them.

This is the form.

drupal8-privatetempstore-form

And this is the controller.

drupal8-privatetempstore-controller

You can find and download the code of this companion module here.

Types of data storage in Drupal 8

In Drupal 8 we have various APIs for data storage:

Database API  - To interact directly with the database.
State API - A key/value storage to store data related to the state or individual environment (dev., staging, production) of a Drupal installation, like external API keys or the last time cron was run.
UserData API - A storage to store data related to an individual environment but specific to a given user, like a flag or some user preferences.
TempStore API - A key/value storage to keep temporary data (private o shared) across several page requests.
Entity API - Used to store content (node, user, comment …) or configuration (views, roles, …) data.
TypedData API - A low level API to create and describe data in a consistent way.    

Our use case refers to user-specific data we need for a short period of time, data that is also not specific to one environment, so the best fit is certainly the TempStore API but in its private flavour because the data and the results are different for each user.

The only difference between private and shared tempstore is that the private tempstore entries strictly belong to a single user whereas with shared tempstore, the entries can be shared between several users.

Storing the form's values with the Private TempStore storage

Our goal is to build a form where user can introduce an RSS file URL and a number of items to retrieve from that file, next we need to store temporarily those values to retrieve them later in a controller.

Let’s now take a closer look at how we could store (or save) our form’s values. As we get the data (url and items to retrieve) from a form, it’s clear that we are going to store the data in the submitForm() method since this method is called when the form is validated and submitted.

Here is the code of our form.

<?php
namespace Drupal\ex_form_values\Form;
use Drupal\Core\Form\FormBase;
use Drupal\Core\Form\FormStateInterface;
// DI.
use Symfony\Component\DependencyInjection\ContainerInterface;
use Drupal\Core\Messenger\MessengerInterface;
use Drupal\Core\Logger\LoggerChannelFactoryInterface;
use Drupal\Core\TempStore\PrivateTempStoreFactory;
/**
 * Class WithControllerForm.
 *
 * Get the url of a RSS file and the number of items to retrieve
 * from this file.
 * Store those two fields (url and items) to a PrivateTempStore object
 * to use them in a controller for processing and displaying
 * the information of the RSS file.
 */
class WithStoreForm extends FormBase {
  /**
   * Drupal\Core\Messenger\MessengerInterface definition.
   *
   * @var \Drupal\Core\Messenger\MessengerInterface
   */
  protected $messenger;
  /**
   * Drupal\Core\Logger\LoggerChannelFactoryInterface definition.
   *
   * @var \Drupal\Core\Logger\LoggerChannelFactoryInterface
   */
  protected $loggerFactory;
  /**
   * Drupal\Core\TempStore\PrivateTempStoreFactory definition.
   *
   * @var \Drupal\Core\TempStore\PrivateTempStoreFactory
   */
  private $tempStoreFactory;
  /**
   * Constructs a new WithControllerForm object.
   */
  public function __construct(
    MessengerInterface $messenger,
    LoggerChannelFactoryInterface $logger_factory,
    PrivateTempStoreFactory $tempStoreFactory
  ) {
    $this->messenger = $messenger;
    $this->loggerFactory = $logger_factory;
    $this->tempStoreFactory = $tempStoreFactory;
  }
  /**
   * {@inheritdoc}
   */
  public static function create(ContainerInterface $container) {
    return new static(
      $container->get('messenger'),
      $container->get('logger.factory'),
      $container->get('tempstore.private')
    );
  }
  /**
   * {@inheritdoc}
   */
  public function getFormId() {
    return 'with_state_form';
  }
  /**
   * {@inheritdoc}
   */
  public function buildForm(array $form, FormStateInterface $form_state) {
    $form['url'] = [
      '#type' => 'url',
      '#title' => $this->t('Url'),
      '#description' => $this->t('Enter the url of the RSS file'),
      '#default_value' => 'https://www.drupal.org/planet/rss.xml',
      '#weight' => '0',
    ];
    $form['items'] = [
      '#type' => 'select',
      '#title' => $this->t('# of items'),
      '#description' => $this->t('Enter the number of items to retrieve'),
      '#options' => [
        '5' => $this->t('5'),
        '10' => $this->t('10'),
        '15' => $this->t('15'),
      ],
      '#default_value' => 5,
      '#weight' => '0',
    ];
    $form['actions'] = [
      '#type' => 'actions',
      '#weight' => '0',
    ];
    // Add a submit button that handles the submission of the form.
    $form['actions']['submit'] = [
      '#type' => 'submit',
      '#value' => $this->t('Submit'),
    ];
    return $form;
  }
  /**
   * Submit the form and redirect to a controller.
   *
   * 1. Save the values of the form into the $params array
   * 2. Create a PrivateTempStore object
   * 3. Store the $params array in the PrivateTempStore object
   * 4. Redirect to the controller for processing.
   *
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    // 1. Set the $params array with the values of the form
    // to save those values in the store.
    $params['url'] = $form_state->getValue('url');
    $params['items'] = $form_state->getValue('items');
    // 2. Create a PrivateTempStore object with the collection 'ex_form_values'.
    $tempstore = $this->tempStoreFactory->get('ex_form_values');
    // 3. Store the $params array with the key 'params'.
    try {
      $tempstore->set('params', $params);
      // 4. Redirect to the simple controller.
      $form_state->setRedirect('ex_form_values.simple_controller_show_item');
    }
    catch (\Exception $error) {
      // Store this error in the log.
      $this->loggerFactory->get('ex_form_values')->alert(t('@err', ['@err' => $error]));
      // Show the user a message.
      $this->messenger->addWarning(t('Unable to proceed, please try again.'));
    }
  }
}

In the submitForm() method we can see two lines where we deal with the private tempstore in step 2 and 3.

$tempstore = $this->tempStoreFactory->get('ex_form_values');
//...
$tempstore->set('params', $params);

In the first line we call the PrivateTempStoreFactory to instantiate a new PrivateTempStore object trough its get() method. As you can see, we get the factory by DI. We also define the name of our collection (ex_form_values) with the same name as our module (by convention) and pass it to the get() method. So, at this time we created a new PrivateTempStore object for a collection named "ex_form_values".

In the second line we use the set() method of the PrivateTempStore object which will store the key/value pair we need to save, in our case, the key is 'params' and the value is the $params array that contains our form’s values.

The PrivateTempStoreFactory uses a storage based on the KeyValueStoreExpirableInterface, this storage is a key/value storage with an expiration date that allows automatic removal of old entities and this storage uses the default DatabaseStorageExpirable storage to save the entries in the key_value_expire table.

Here is the structure of this table:

key_value_expire-strucuture

The PrivateTempStore object has the following protected properties, all passed to the form by DI:
$storage - The key/value storage object used for this data.
$lockBackend - The lock object used for this data.
$currentUser - The current user who owned the data. If he's anonymous, the session ID will be used.
$requestStack - Service to start a session for anonymous user
$expire - The time to live for the entry in seconds. By default, entries are stored for one week (604800 seconds) before expiring as defined in the KeyValueStoreExpirableInterface.

We can’t set any of those values, they are all set by the KeyValueStoreExpirableInterface when we instantiate the new PrivateTempStore object.

The PrivateTempStore object method we are interested at this time is the set() method which will store the key/value we need to save, in our case, the key is 'params' and the value is the $params array that contains our form’s values. You can find the code of this method here and below, the beginning of this method:

public function set($key, $value) {

  // Ensure that an anonymous user has a session created for them, as
  // otherwise subsequent page loads will not be able to retrieve their
  // tempstore data.
  if ($this->currentUser
    ->isAnonymous()) {

    // @todo when https://www.drupal.org/node/2865991 is resolved, use force
    //   start session API rather than setting an arbitrary value directly.
    $this
      ->startSession();
    $this->requestStack
      ->getCurrentRequest()
      ->getSession()
      ->set('core.tempstore.private', TRUE);
  }
  // ....
}

As you can see at the beginning of this method, we ensure that an anonymous user has a session created for him, thanks to this, we can also retrieve a session ID that we will use to identify him. If it’s an authenticated user, we will use his UID. You can confirm that in the getOwner() method of the PrivateTempStore object.

When we submit the form, thanks to these two lines, we’ll save the form's values in the database. If you look at the key_value_expire table, you can see that there are other records, most of them with update information of our app., but also new records with the collection value of tempstore.private.ex_form_values. Here is a query on this collection when an anonymous and the admin user use the form.

key_value_expire-drupal8

We didn’t output the column 'value' because it’s too large. But you can see now how our form's values are stored in the database and particularly for anonymous users with their session ID.

At this time, we know how to store temporarily the values of a form in the privatetempstore of Drupal. This was not so hard, wasn’t it? Yes, Drupal is a great framework and it saves us a lot of time when developing a web application.

Now let’s see how to retrieve and process the values in a controller.

Retrieve our form's values from the privatetempstore

To retrieve the data, process them and display the results, we’ll need to redirect our form to a controller. Here is the code of this controller.

<?php
namespace Drupal\ex_form_values\Controller;
use Drupal\Core\Controller\ControllerBase;
// DI.
use Drupal\Core\Messenger\MessengerInterface;
use Drupal\ex_form_values\MyServices;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Drupal\Core\TempStore\PrivateTempStoreFactory;
use GuzzleHttp\ClientInterface;
// Other.
use Drupal\Core\Url;
/**
 * Target controller of the WithStoreForm.php .
 */
class SimpleController extends ControllerBase {
  /**
   * Tempstore service.
   *
   * @var \Drupal\Core\TempStore\PrivateTempStoreFactory
   */
  protected $tempStoreFactory;
  /**
   * GuzzleHttp\ClientInterface definition.
   *
   * @var \GuzzleHttp\ClientInterface
   */
  protected $clientRequest;
  /**
   * Messenger service.
   *
   * @var \\Drupal\Core\Messenger\MessengerInterface
   */
  protected $messenger;
  /**
   * Custom service.
   *
   * @var \Drupal\ex_form_values\MyServices
   */
  private $myServices;
  /**
   * Inject services.
   */
  public function __construct(PrivateTempStoreFactory $tempStoreFactory,
                              ClientInterface $clientRequest,
                              MessengerInterface $messenger,
                              MyServices $myServices) {
    $this->tempStoreFactory = $tempStoreFactory;
    $this->clientRequest = $clientRequest;
    $this->messenger = $messenger;
    $this->myServices = $myServices;
  }
  /**
   * {@inheritdoc}
   */
  public static function create(ContainerInterface $container) {
    return new static(
      $container->get('tempstore.private'),
      $container->get('http_client'),
      $container->get('messenger'),
      $container->get('ex_form_values.myservices')
    );
  }
  /**
   * Target method of the the WithStoreForm.php.
   *
   * 1. Get the parameters from the tempstore for this user
   * 2. Delete the PrivateTempStore data from the database (not mandatory)
   * 3. Display a simple message with the data retrieved from the tempstore
   * 4. Get the items from the rss file in a renderable array
   * 5. Create a link back to the form
   * 6. Render the array.
   *
   * @return array
   *   An render array.
   */
  public function showRssItems() {
    // 1. Get the parameters from the tempstore.
    $tempstore = $this->tempStoreFactory->get('ex_form_values');
    $params = $tempstore->get('params');
    $url = $params['url'];
    $items = $params['items'];
    // 2. We can now delete the data in the temp storage
    // Its not mandatory since the record in the key_value_expire table
    // will expire normally in a week.
    // We comment this task for the moment, so we can see the values
    // stored in the key_value_expire table.
    /*
    try {
      $tempstore->delete('params');
    }
    catch (\Exception $error) {
      $this->loggerFactory->get('ex_form_values')->alert(t('@err',['@err' => $error]));
    }
    */
    // 3. Display a simple message with the data retrieved from the tempstore
    // Set a cache tag, so when an anonymous user enter in the form
    // we can invalidate this cache.
    $build[]['message'] = [
      '#type' => 'markup',
      '#markup' => t("Url: @url - Items: @items", ['@url' => $url, '@items' => $items]),
    ];
    // 4. Get the items from the rss file in a renderable array.
    if ($articles = $this->myServices->getItemFromRss($url, $items)) {
      // Create a render array with the results.
      $build[]['data_table'] = $this->myServices->buildTheRender($articles);
    }
    // 5. Create a link back to the form.
    $build[]['back'] = [
      '#type' => 'link',
      '#title' => 'Back to the form',
      '#url' => URL::fromRoute('ex_form_values.with_store_form'),
    ];
    // Prevent the rendered array from being cached.
    $build['#cache']['max-age'] = 0;
    // 6. Render the array.
    return $build;
  }
}

First we inject all the services we need and also a custom service MyServices.php used to retrieve the RSS file and the required number of items.

This controller has a simple method called showRssItems(). This method performs six tasks:

1. Get the data we need from the PrivateTempstore
2. Delete the PrivateTempStore data from the database (not mandatory)
3. Display a simple message with the data retrieved from the tempstore
4. Get the items from the rss file in a render array
5. Create a link back to the form
6. Render the array.

The tasks that interest us are the first and the second one, where we deal with the tempstore.

$tempstore = $this->tempStoreFactory->get('ex_form_values');

This line is now straightforward for us, since we know that the get() method of the PrivateTempStoreFactory instantiate a new PrivateTempStore object for the collection 'ex_form_values'. Nothing new here.

$params = $tempstore->get('params');

In the line above, we just retrieve the value of the key 'params' from the storage collection into the variable $params. Remember that we are using the privatetempstorage, as we retrieve the value, we’ll also check if it's the same user with the getOwner() method of the PrivateTempStore object.

The second task is deleting the data from the tempstore, this is not mandatory since we are working with a temporary store where the data will be deleted automatically after a week by default. But if we expect a heavy use of our form, it could be a good idea since we won’t normally need the data anymore.

try {
  $tempstore->delete('params');
}
catch (\Exception $error) {
  $this->loggerFactory->get('ex_form_values')->alert(t('@err',['@err' => $error]));
}

As the delete() method of our privatetempstore object can trow an error, we’ll catch it in a 'try catch' block. For learning purpose I’ll suggest to comment those lines to see how the data are stored in the key_value_expire table.

The rest of the controller is pretty straightforward, we are going to pass the data to small methods of our custom service to retrieve the RSS file and the number of items we need, build a render array with the results as you can see in task number four. Next, we’ll create a simple link back to our form and render the entire array. Nothing strange here.

Recap

We wanted, trough a form, to get a RSS file URL, the number of items to retrieve from, and display this information in a controller. To do so, we needed to store the information of the form, retrieve it and process it later in a controller.

We decided to use the Private TempSore system of Drupal because:
- The information doesn’t belong to a specific environment or a particular state of our application (see State API for that case)
- The information is not specific to a user and doesn’t need to be stored with its profile (see UserData API for that case). On the other hand, anonymous users should also have access and use the form
- We need the information temporarily, for a short period of time
- It has to be private because the information belongs to each user (anonymous or authenticated)

To store the data, we used the submit() method of our form and the following lines:

$tempstore = $this->tempStoreFactory->get('ex_form_values') - to instantiate a new PrivateTempStore object with a collection name 'ex_form_values' that refers to our module in this case.

$tempstore->set('params', $params) - to save the value of the variable $params in the database with the key 'params'. Remember that as we use a private storage, Drupal will retrieve the user ID or its session ID if anonymous, and concatenate it with the key value in the 'name' row of the 'key_value_expire' table.

To retrieve the information in our controller’s showRssItems() method, we used the following code:

$tempstore = $this->tempStoreFactory->get('ex_form_values') - to instantiate a new PrivateTempStore object with a collection name 'ex_form_values' that refers to our module in this case.

$params = $tempstore->get('params') - to retrieve the value stored in the keyed 'params' record of this collection and for this particular user.

Yes! Once again, through this simple example, we can see how powerful Drupal is, and how its framework is easy to use.

And you? In which situation do you think we could use the privatetempstore? Please, share your ideas with the community.

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