Drupal

Jacob Rockowitz: Webform 8.x-5.x stable release plan

Planet Drupal - 5 February 2019 - 7:38am

Looking back

Three years ago on Christmas day, I tagged the first alpha of the YAML Form module, which became the Webform module for Drupal 8. Looking back, it has been a great learning experience building and maintaining the Webform module. Looking forward, I want to make sure the Webform module is as stable as possible while still trying to smooth out any rough edges around accessibility and user experience. Everyone should feel that the Webform module is a stable, supported, and maintained part of Drupal's ecosystem of contributed modules. To help organizations and individuals understand what to expect from a stable release of the Webform module, it’s worth defining some general goals.

Setting goals

The goals of this blog post and the overall stability of the Webform module are to…

  • Define the ongoing stable release cycle.

  • Document what to expect from stable releases.

  • Encourage the growth of Webform add-ons and integrations.

Tagging releases

For the past three years, I've been tagging a new release at the beginning of each month. Frequently monthly releases were quickly followed up with a hotfix release to address unexpected regressions. Regressions happen because the Webform module is a feature-rich application with maybe not enough test coverage and definitely not enough eyeballs reviewing the code. Quality assurance is a challenge for open source projects; reviewing code for free is not as much fun as writing it. Even Drupal core needs help with improving the reliability of minor updates.

For example, Webform 8.x-5.1 was released at the...Read More

Categories: Drupal

ComputerMinds.co.uk: A/B Testing with ABJS module

Planet Drupal - 5 February 2019 - 5:00am

ABJS is a contrib Drupal module, and, without any requirements or ties to paid services, is as low cost as you can get. As we’ll see, it’s pretty basic but it really lets you get down to building your own understanding of how A/B testing works. The beauty of ABJS is in its simplicity. The settings pages are fairly self-explanatory, which is really helpful. Let’s set up a basic A/B test to show how things work.

Setting up our first experience

In our test, we’re going to split the site 50:50 in order to test an alternate homepage design. Go to /admin/config/user-interface/abjs and get a feel for things. See the tabs across the top? The best way to set up a new test is to work backwards. That’s because your Tests will need to reference your Conditions and Experiences - and you’ll need to create them before you can use them.

First up, create an Experience. Experiences make the actual A’s and B’s of your A/B tests. Go to the Experiences tab. Give your experience a very clear and helpful name. Our first one will be our normal homepage experience. Making a ‘normal’ experience allows us to explicitly log our page views for our analytics.

The Javascript we set up for our site looks like this:

if (typeof(ga) !== "undefined") { ga('set', 'dimension1', 'normal'); } window.Drupal = window.Drupal || { 'settings': {}, 'behaviors': {}, 'locale': {} }; window.Drupal.behaviors.abtesting = { attach: function(context, settings) { jQuery('#request-a-quote-form').on('submit', function() { ga('send', 'event','Productfinder', 'ID search', 'Homepage'); }); } }

1. We came to the Drupal Behavior format after realising that the ABJS scripts in the header would run before the Google Analytics scripts, and we would need the GA script to run before we could log our analytics. You could probably do this another way if you wanted, but this is easy enough to copy and paste for now.

2. Set our custom GA dimension.

3. This ends up happening before Drupal is actually ready to accept and execute behaviors, hence the very careful creation/copy of the window.Drupal variable.

4. Add a submit handler to our form, which will send an event to GA. This is the thing we’re trying to measure. Hopefully our alternate version of the page will result in more clicks on this button, and we’ll be able to track those in GA.

If you copy & paste the above, you'll want to make your tweaks:

1. Change the first call to ga() in line 2 to be a dimension you’ve set up in Google Analytics (Go do that now! Their support articles are really good, so I won’t explain that here).

2. Set the value for that call to be the value you want (‘normal’ may well be fine).

3. Change the event values in the final call to ga() to send the event values you want or need. They don’t need to be fancy, just unique - you just need to be able to track them in GA. Now, go create an “Alternate homepage experience” experience.

Set up your Alternate Experience

This is the Experience for the change / difference you're wanting to test.

Copy the JS from your ‘Normal’ experience, and tweak it to:

1. Have a different value for your GA dimension

2. Make an actual change to your page. Put this after the jQuery/ga call.

Now go create your condition(s).

All your experience Javascript will be added to every page, so this is where you make sure that you’re only running things where and when you really want to. Again, you write up some Javascript; it will return a Boolean value indicating to ABJS whether you want your test to be run. In our example, we’re just testing the homepage. So we’ll just do this:

return (window.location.pathname == "/");

Don't forget to set a helpful and clear name for your Condition, so it's easy to select later.


Test time!

At last, you can now go set up your Test.

1. Give your test a name. Make it helpful, so that you know which test does what when you have multiple tests later :) Perhaps name it after the change you’re making in your alternate test.

2. Select your two experiences in the two select boxes. Don’t let the fraction field confuse you - this is just the proportion of people you want to be diverted to each of your two experiences. This can be super helpful if you want, for example, to test something on a small proportion of users. For us doing our small, low-cost A/B test on our small client’s site, we want to maximise our data. So we’re doing 50:50 - this means fractions of 0.5 and 0.5 You can have multiple experiences here, which is pretty neat. So if you want to test multiple variations of your homepage, you can! Go for it!

3. Double check your Javascript :) Go execute it in the browser console or something, to make sure it works. No point taking your site down accidentally!

4. Set your test to 'Active'! This will add your tests to the site, so you can start collecting data! Now is the time to go to Google Analytics and watch the data pour in (for some definition of pour, depending on how busy your site is right now!).


Analysing your data

A key thing to remember when watching your analytics is that things change all the time, and sometimes randomness can be responsible for what you’re seeing. Or maybe there was a seasonal spike in sales which increased revenue that week, or maybe you’re not filtering your users to the right segment… A few recommendations for you:

  • Create segments for your two dimension values, so you can easily filter your data.
  • Data can be misleading. Always check other angles before declaring you’ve fixed the problem.
  • Run your numbers to check the Statistical Significance. If you don’t have tens of thousands of samples, your results may just be random chatter rather than necessarily related to the changes your Experience made. Either remember your A-Level statistics, or go use an online calculator. I recommend https://measuringu.com/statistically-significant/ for a good explainer.
  • If your site is not high traffic, you may need to run your tests for weeks or even months to get enough data to clearly show whether there's a difference. Or, it may be worth deciding that there's not clearly a difference, so it's worth testing something else.
     

     

So, we’ve created some tests with ABJS. How did it go?

Overall, ABJS is nice because it feels like you’re in control. And all developers like to feel in control. It’s also nice because if you want to go set up a test, you can! It’s easy!

Where ABJS loses out is in the pile of lovely features that the big products out there can offer. Creating, managing, scheduling and analysing are all tasks that have been made a lot easier by some off-the-shelf products. But if you can’t afford that budget, or really rather enjoy thinking things through (or indeed love a bit of statistics!) then this is your lot - and it works well enough.

Later on in the series we'll be playing with Google Analytics' A/B testing suite and seeing how it compares. Stay tuned!

Categories: Drupal

CTI Digital: How do you start contributing to Drupal without code?

Planet Drupal - 5 February 2019 - 2:27am

Outlets for contributing to Drupal beyond code, whilst abundant, are not always evident to those having interest to do so. I want to help people become better acquainted with ways to get involved and how to start their contribution journey. Be they completely new to Drupal or simply yet to find an outlet.

Categories: Drupal

Agiledrop.com Blog: Top Drupal blog posts from January 2019

Planet Drupal - 5 February 2019 - 12:25am

Just like every month, we’ve prepared a selection of the most interesting and engaging Drupal-related blog posts from the previous month. Check out January’s list and make sure you haven’t missed any!

READ MORE
Categories: Drupal

Social Auth PBS

New Drupal Modules - 4 February 2019 - 2:25pm

This project is part of the Drupal Social Initiative and is based on the Social API.

About

Social Auth PBS allows users to register and log in to a Drupal site using a PBS.org account.

Categories: Drupal

Entity Strip

New Drupal Modules - 4 February 2019 - 11:02am

The Entity Strip module is a drush command that takes in a list of entities and spits out configuration to exclude the tables related to that entity in a database dump.

Categories: Drupal

Compressor

New Drupal Modules - 4 February 2019 - 7:38am

Module for improving PageSpeed ​​Insights index.
1. Processing pictures (removes comments)
2. Insert small images in HTML (base64)
3. Compressing JS and insert into page code
4. Compressing CSS and insert into page code

Categories: Drupal

Social Course

New Drupal Modules - 4 February 2019 - 6:13am

This module allows Community Managers to create courses for their members.
A Course is a step-by-step program that guides users through a course complete
with video, text and an opportunity for users to keep track of their progress.
You can look up courses via the all courses overview, usually positioned
under the explore menu.

Categories: Drupal

Social JSON API

New Drupal Modules - 4 February 2019 - 5:35am

Social JSON API provides an API which can be used with the following entities:

  • comment
  • event_enrollment
  • file
  • group
  • group_content
  • node
  • post
  • profile
  • taxonomy_term
  • user

It works out of the box for these entities. However you'll need to do some configuration to access the API (authentication and authorization).

Categories: Drupal

Spinning Code: SCDUG November 2018

Planet Drupal - 4 February 2019 - 5:00am

This fall the South Carolina Drupal User’s Group started using Zoom are part of all our meetings. Sometimes the technology has worked better than others, but when it works in our favor we are recording the presentations and sharing them when we can.

In November Kaylan Wagner gave a draft talk on using experiences in the world of online gaming to be a better remote team member.

We frequently use these presentations to practice new presentations and test out new ideas. If you want to see a polished version hunt group members out at camps and cons. So if some of the content of these videos seems a bit rough please understand we are all learning all the time and we are open to constructive feedback.

If you would like to join us please check out our up coming events on Meetup for meeting times, locations, and connection information.

Categories: Drupal

DrupalEasy: DrupalEasy Podcast 215 - Kaleem Clarkson - Drupal Event Organizers Working Group

Planet Drupal - 4 February 2019 - 4:00am

Direct .mp3 file download.

Kaleem Clarkson, Operations Manager and Front-End Drupal Developer at Kennesaw State University and Drupal developer at blend me inc. Listen in as they discuss the newly formed Drupal Event Organizers Group and Mike breaks bad news about the Marvel Universe to Kaleem.

Discussion DrupalEasy News Upcoming Events Sponsors 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.

Categories: Drupal

Selective Better Exposed Filters

New Drupal Modules - 4 February 2019 - 3:10am

Provide extra option for better exposed filters to show only used terms in filter. This module is very simple and just add a part of fuctionality of Views Selective Filters (https://www.drupal.org/project/views_selective_filters) to Better Exposed Filters module. Module provide checkbox "Show only used terms" and work only with Taxonomy term reference fields.

Categories: Drupal

No   (no-break space)

New Drupal Modules - 3 February 2019 - 11:46pm

no_nbsp is a very simple filter module that deletes all no-break spaces and does nothing else.

Categories: Drupal

Language Switcher Extended

New Drupal Modules - 3 February 2019 - 7:25am

The Language Switcher Extended module provides additional processors for the language switcher block links.

Categories: Drupal

Matt Glaman: Testing your Drupal code base for deprecated code usage with PHPStan

Planet Drupal - 3 February 2019 - 7:14am
Testing your Drupal code base for deprecated code usage with PHPStan Sunday 3, February 2019 mglaman

Last month I wrote about writing better Drupal code with static analysis using PHPStan. One of the more practical uses I saw for PHPStan and Drupal was the discovery of deprecated code usages through the phpstan/phpstan-deprecation-rules package. I had not fully tested it, until this week. 

Categories: Drupal

blog.studio.gd: Drupal 8 Views Plugins (Part 2) : The display extender plugin

Planet Drupal - 3 February 2019 - 12:04am
Let's see how and why to use a views display extender plugin.
Categories: Drupal

blog.studio.gd: Views Plugins (Part 1) : Simple area handler plugin

Planet Drupal - 3 February 2019 - 12:04am
In this series I will show you how to make use of the new Drupal 8 Plugin system, we begin with a simple example : the views area handler plugins.
Categories: Drupal

blog.studio.gd: Overview of CMI in Drupal 8

Planet Drupal - 3 February 2019 - 12:04am
Some notes about the new Configuration management system in Drupal 8
Categories: Drupal

blog.studio.gd: Migrate to Drupal 8 from a custom site

Planet Drupal - 3 February 2019 - 12:04am
Migrate is now included in the Drupal core for making the upgrade path from 6.x and 7.x versions to Drupal 8.

In this article will see how to use the Drupal migration framework to migrate custom sites to drupal 8.
Categories: Drupal

blog.studio.gd: Inline Entity Display

Planet Drupal - 3 February 2019 - 12:04am
Handle referenced entity fields directly in the parent entity
Categories: Drupal

Pages

Subscribe to As If Productions aggregator - Drupal