Lately, I've been working a lot with Ansible, a simple but powerful infrastructure management platform. I now use Ansible playbooks and ad-hoc commands to manage all of Midwestern Mac's infrastructure (this site, Hosted Apache Solr, Server Check.in, and many ancillary servers, and as a result, I've started using Ansible for pretty much any kind of work I need to do in development—including configuring my own Mac, and developing with Drupal 8 (among other things).Meet Ansible
For those who haven't heard of Ansible before, it's often described as being a little like Puppet or Chef, used for configuration management. You define the configuration of a server, and Ansible makes sure the server is configured as defined. But Ansible goes quite a bit further—it's also great for deploying applications (especially in tandem with tools like Jenkins), running commands on servers, and day-to-day management of a few, hundreds, or even thousands, of servers—it's an end-to-end configuration management tool. Ansible also has a great, and rapidly-growing community, building it up and making it markedly better every release.
Ansible uses YAML to define configuration (just like Drupal 8!), and is relatively easy to pick up, especially if you already have some experience on the command line. You can read more about it in a book I'm writing, Ansible for DevOps, and hopefully, I'll be able to tell you more about Ansible in person at DrupalCon Austin—I've submitted a session titled DevOps for Humans: Ansible for Drupal Deployment Victory! (please leave a comment and let me know what you want to hear!).Drupal development VM (Vagrant + Ansible)
I used to use MAMP (a simple-to-install Apache + MySQL + PHP setup for Macs) for all my development, which made adding virtual hosts to Apache relatively simple. However, there are many downsides to developing with MAMP—I could never configure things like drush, APC, the version of PHP, MySQL, or auxiliary tools like XDebug and Solr, exactly how I wanted or needed them.
In an effort to continue helping organizations engage and stay sticky with their customers, we partnered with Silverpop to release the Silverpop Engage Drupal module. Silverpop, a leader in marketing automation, partnered with Mediacurrent to provide direction on the module’s feature set and API integration. Now, digital marketers can seamlessly add Silverpop’s visitor tracking capabilities to their Drupal website by installing the module and entering a few configuration settings.
Let’s take a look at features that are available in the this initial release of Silverpop Engage.
- Web page tracking
- Custom event tracking
- Webform lead integration
In this episode Addison Berry is joined by Lorna Jane Mitchell and Joe Fender to step outside of Drupal a little and look at the larger PHP landscape. We discuss what all this talk of Object Oriented Programming (OOP) means. Lorna Jane is a PHP and API specialist and has written several books about PHP, and specifically about OO in PHP. Joe is a developer on the Drupalize.Me team who has been digging into Drupal 8.
Pictures. Podcasts. Videos. If you've ever tried to incorporate rich media files into your web site using only Drupal core, you probably got a shiver down your spine when I said that. Fortunately there is a solution.
We are excited to announce that registration and session proposals are now open for Stanford Drupal Camp 2014!
Registration is now open for the Fifth Annual Stanford Drupal Camp. All sessions will be held April 18th - 19th, 2014 at the Stanford Engineering Quad.
Drupal Association News: Unplanned Drupal.org Downtime Earlier Today (Thu Feb 13 14:59-15:21 UTC 2014)
The Drupal.org primary database server experienced a crash due to a full disk earlier today around 6:59am PST (14:59 UTC).
Ah, breadcrumbs, how I hate you. Such a tiny little piece of a site, yet so much complexity and time spent. For some clients, you would think this is their number one must have feature based on how much time they spend checking and critiquing them page-by-page.Existing solutions
In typical Drupal fashion, "there's a module for that!" Or more truthfully, "there are 17 modules for that!" Let's run down a few.
Please note that I am NOT hating on these modules because they're bad. Most of them are actually quite good for the tough problem they're trying to solve.Custom Breadcrumbs
Custom Breadcrumbs is perhaps one of the earliest modules for this, dating all the way back to 2006. It has a bunch of submodules and a fancy interface that looks like this:
And that's just nodes. There are also interfaces for Views, Panels, Taxonomy, and Paths. Now, I'm not saying this interface is bad--it's not. But I bet you couldn't understand it at first glance. That's because breadcrumbs are just a hard thing to configure visually. (I'm going to say that again so be ready).
How much code does Custom Breadcrumbs ship with?
That's 6258 lines, counting a few text files and comments and blank lines. For Breadcrumbs. Debugging when things don't work as they should is obviously no picnic.Crumbs
Crumbs is less than 4 years old so it's just a toddler compared to Custom Breadcrumbs. Let's take a look at a few of its admin pages.
Here's how you specify a breadcrumb pattern for content:
And here's a snippet of how you choose which plugins take priority over other plugins:
Again, these aren't bad interfaces by any means. They're just symptoms of the problem, which is that breadcrumbs are just a hard thing to configure visually.
How about code?
Crumbs currently ships with 9135 lines of code, again including text files and comments and blank lines.Hansel
Hansel is about as old as Crumbs and touts the slogan "Breadcrumbs done right!" It contains 7 modules (one each for Domain, OG, Taxonomy, Forum, Exporting, the UI, and core functionality) and weighs in at a lightweight 4421 lines currently.
Here's what it looks like:
Would you know what to enter where on that screen? Would you know how to build out breadcrumbs for nodes tagged with a taxonomy using that? Yet again, this isn't a problem with the module, the module is fine. Breadcrumbs are just a hard thing to configure visually.Others
This list is by no means complete. Here are a few others that exist and are, in my perhaps grumpy opinion, either lacking in functionality or equally as bulky and confusing.
- Path Breadcrumbs (here's a screenshot)
- Breadcrumbs By Path (only works for items that follow a predictable nested URL aliasing convention)
- Menu Breadcrumb (only works for items in menus)
- Others? If you know of another breadcrumb module that you absolutely love, feel free to tell me all about it in the comments.
Easy! Breadcrumbs are just a hard thing to configure visually!
They can depend on so many things and they need to satisfy so many different use cases, that it's just really hard to support all of that and do it in a way that isn't a GUI onslaught.
Let's take a specific example. Say we have just one single content type (just one!) called "Story". And let's pretend that there's a "Category" taxonomy attached to it. Here are some very common and completely valid ways one might want to set up those breadcrumbs:
- Make all news authored by a specific user named John Writer follow the "Editorials > John Doe > Title Of Post" pattern.
- Make all news under the "Press Release" taxonomy term (in the Categories vocabulary) follow the "Press Releases > Title Of Post" pattern
- Make all news posted before the current calendar year follow the "News Archive > Year > Month > Title Of Post" pattern
- Make all news posted in the "Blog" taxonomy term follow the "Blog > Author's Name > Year > Month > Title Of Post" pattern
So that's four completely different use cases all on the same content type with only one taxonomy attached to it. That doesn't even touch on multiple content types, multiple taxonomies, different entities (user profiles, and Drupal Commerce products are quite common) or even non-entity pages (Views pages, Panels pages, etc.).
Do you see what I mean? It's a losing game.
Blame "Invented Here" syndrome or Drupal's love of all things GUI, or both. Either way, most people are trying to make the best of a bad thing by working around the various failings of these contrib modules.An alternative approach
You are a programmer. Do it in code. It's easy! Just use our friend drupal_set_breadcrumb() like so:
Here's a rundown of how you could satisfy the 4 use cases above in code, in a few minutes.
- Use hook_node_view($node), grab the author out of $node->uid, and if it's John Writer, set that custom beadcrumb using drupal_set_breadcrumb().
- Use hook_node_view($node), grab the category out of $node->field_news_categories (or whatever the field is called), and run taxonomy_term_load() to grab the whole term, and if the $term->name is "Press Release", then set that breadcrumb.
- Use hook_node_view($node), and if date('Y', $node->created) < date('Y') then set the breadcrumb by passing date('Y', $node->created) and date('F', $node->created) into drupal_set_breadcrumb() for the year and month.
- Same basic idea as #2 above.
Or maybe you're adding breadcrumbs for a Views page? Throw it in a Views hook like hook_views_pre_render(&$view). Oh, you're trying to add breadcrumbs to a taxonomy term page? Throw a drupal_set_breadcrumb() into hook_taxonomy_term_view($term) and call it a day.
See what I mean? This is basic stuff for any Drupal developer, and it saves you many thousands of lines of code and potentially a lot of time debugging that code and trying to understand the interfaces.Caveats
This method won't work when you're dealing with either of the following scenarios:
- You need to accommodate new breadcrumb patterns as things are changed without being able to make code changes. For example, a new promotion is being run tomorrow, with no notice, and that's not enough time to push a code change through QA and find a decent launch window by then. Or maybe you're just an editor who doesn't have code access at all.
- You need to accommodate clients who want to add and configure their own breadcrumbs without relying on you to code it. There's still the difficulty in getting them a module with a UX they can wrap their non-technical brains around, but it's more doable than teaching them to code.
However, if you're not in one of those two situations, then I highly recommend you rid yourself of whatever breadcrumb GUI you've been using.
Or convince the client to get rid of breadcrumbs altogether!Read this next: Drupal and “Invented Here”
22nd Winter Olympics 2014 in Sochi mobilized sports websites around the globe.
If you're going to use popular software like Drupal, one of the downsides is that you'll need to deal with spam.
A lot of OSTraining members report that they many spam user registrations on their site.
In this blog post, we'll look at 10 of the best ways to avoid getting overwhelmed by spam users.
As you know, DrupalCon is just a few short months away and this year we're proud to be hosting it in sunny Austin, Texas. It's session proposal time and this year we are helping to organize the Business & Strategy track. I'm writing to ask you all to submit your session proposals so that we can make this year's DrupalCon the best one yet.Now a bit about the Business & Strategy Track...
This track is for those looking to improve the way that they sell, conceptualize, plan, estimate, manage, or deliver Drupal services and products. Experienced business professionals will share their knowledge and experience on topics such as project management, client communication, team building, culture, and organizational leadership. Sessions in this track will be non-technical in nature.Main themes include:
- Project management, planning, and strategy
- Team management, growth, and business best practices
- Customer service, communication, and marketing
Technology executives, business owners, project and product managers, and others responsible for leading projects or guiding technology decisions and processes within their company or organization. Anyone who wants to improve their company or organization’s ability to deliver Drupal solutions.
The call for sessions is open until March 7, 2014 at 11:59pm CT.Category: DrupalDrupal Planet
This year Google celebrates the 10th birthday of their global program „Google Summer of Code“. The open source program offers student developers over the age of 18 the possibility for a scholarship. Mentoring organizations' application deadline is February 14th.
Google Summer of Code (GSoC) is very popular amongst projects of the open source scene, because students can take on tasks that otherwise wouldn't get done. Participants earn scholarship funds of 5.500 USD, of which 500 USD go to the specific project and their mentors. This concept has a very high success rate and the participator list shows almost all popular open source projects.
We at undpaul love Drupal and the open source idea, which is why we decided to provide mentors to support the development of the Drupal modules FluxPocket, Leaflet and Paragraphs. You can view our proposals in the Task Organization Wiki at groups.drupal.org.
Also make sure to check out these links if you're interested in mentoring or applying for a scholarship.
450 people, in
39 locations, on
worked on Drupal contrib and core (on core alone: 2468 comments on 646 Drupal 8 issues)
during the Global Sprint Weekend.
The User Experience Design (UXD) track is the place to learn about all things UX, content strategy, and visual design for Drupal.
We are inviting community members to submit sessions related to the following topics:
Before the web was used to provide users data access and to automate customer service, there were IVRs. You know these ubiquitous technologies by experience if not by name. You use them to pay bills by phone, check account balances or even register for classes.
If you're trying to make your Drupal site as fast as possible, you might consider using a static HTML file for page not found (404) errors. There are various other solutions that can help make Drupal faster in these situations while still letting you take advantage of Drupal-level redirects and whatnot, but a static page is always the fastest.Read more
Here at Redfin we've come up with a couple of helpful Drush commands that help us with our everyday workflows. The first shows a database string as a URI for Drush aliases, and the second reverts all views that are in an overridden state without any prompting or confirmation.Twitter Facebook
Using Drupal as a platform for fundraising and advocacy usually means having to integrate with several third-party systems. Beyond the expense, this creates situations that make it hard to get a complete picture of your constituency. To solve this problem we are thrilled to announce we have released AbleOrganizer, a community engagement platform and are excited to show you how it works.
Right now, there are nine, highly motivated people on the East Coast of Florida who are burning the midnight oil... focusing evenings on classes and labs, and days on projects and resources to master the Drupal skills that build new careers and make them valuable members of the Drupal Community. They are the select few of the 2014 Drupal Career Starter Program, and in less than two months, most will be ready for work experience as interns.-->
Last week we deployed a major improvement for issue page workflow: https://drupal.org/node/2159813. The issue edit form is back on the issue page, instead of the standard comment form. Huge thanks to webchick, Mark Carver, sanchiz, Bojhan, joachim and everyone else who worked on the issue.