Software
Code Karate: Multiple Views Part 1

In this episode you will learn how to set up the foundation of building a view that can display content in multiple ways. This video highlights how to set up the content type and view to display the content. In the coming videos in this series you will learn how to style and apply jQuery to change how the view displays the content.
Tags: DrupalContent TypesViewsDrupal 7Site BuildingDrupal PlanetCSSJavascriptJQueryBlair Wadman: How to (almost) eliminate comment spam with Drupal
A few weeks ago I was ready to turn off the comments on my blog. Despite having Mollom running, I was left with a non trivial amount of spam comments to manually deal with each day. It felt like a waste of my time. I love the great comments I get. But there are always people who want to ruin the party, and for the web, it is spammers.
On its own, Mollom is not effective enough.
Tags: Drupal Site buildingPlanet DrupalCraig Aschbrenner: Email fields missing feature? Email Confirmation!
On previous Drupal projects I've had the requirement to provide some sort of confirmation email to email addresses entered into an Email (module) field. These were typically fields like "Work Email" or "Secondary Email". I had written a few small custom modules to handle these cases but found myself repeating the same thing. I knew that this could be useful as a contrib but never got around to it.
I recently had a requirement to confirm email changes to the user account email (e.g. $user->mail). I went to my goto module for this situation, the Email Confirm module. But this time I decided to dive deeper into what Email Confirm was actually doing... and it looked fairly straight forward. I was hoping that I could possibly extend this module to be used with an Email field, but that ended up not being the case.
So I decided to take the plunge and create the Email Field Confirm module. Boy was I in for a ride...
The Email Confirm module only works with the User entity which happens to have the $user->data property / db table. The module makes use of this to avoid any schema changes and retains the relationship of the new email address to the user account. I had started out down a similar path but came to realize this wasn't going to work for entities other than the User entity. Node entities do not have the data property and I couldn't rely on other entity types to have it. This is the point that I realized this was not going to be a simple module.
Time to really sit down and figure out what this module needed to do.
My goal was to allow for any new email address added to an Email Field to be (optionally) confirmed. A field can be reused on multiple entity types and bundles so I need to allow for configuration at the field instance along with storing any pending email address data down to the specific entity instance (e.g. entity_id). I also noticed that the Email Confirm module would stash the new email address away until it was confirmed so I added that to my list of desired features for Email Field Confirm.
Just tell me what it does already!
FeaturesAt a high level, it met the goals I was after. A confirmation email will be sent to any new email addresses that have not already been confirmed by the same user elsewhere (e.g. another Email field) on the site. A field instance can optionally be configured to save the new email address with the entity or keep the original email address until the new one is confirmed.
This works on both single-value and multi-value Email fields, however there are some limitations with the multi-value field.
With multi-value fields it has proven more difficult to accurately identify what the original email value may be have been. I wasn't able to easily identify if the end user was changing an email address vs. just removing and adding another. It is also easy to re-order the values of a multi-value field so relying on the $delta wasn't helpful.
So with single-value fields we have the capability to retain the original email address until the new email address is confirmed. We also have the option to notify the original email address that a change has been made.
Some other notable features include:
- Ability to resend a pending non-expired confirmation email.
- Configure if the acting user (e.g. the user adding the email address) or the entity author/owner is responsible for confirming the email address.
- Hooks for email confirmation and expiration. This module actually makes use of these to handle updating / revering single value email fields to the new or original value.
- Rules integration -- with events similar to the aforementioned hooks.
- Permission to bypass email confirmation. (typically for trusted roles.)
- Permission to manually confirm any email address. (typically for administrative roles.)
- Configurable confirmation and notification emails with token replacement.
There is currently a beta release available for download on the Email Field Confirm project page. It has been pretty stable so far. Besides having more sites use the module and report back and defects or feature requests, I hope to get some automated testing (most likely Behat) in place.
Paul Rowell: Repeatable fieldsets in Drupal: Inline Entity Form Vs Field Collection

My last post on field collections involved revisioning with Workbench Moderation and the issues faced. Since then the module has been developed further, but I've also come across a potential replacement: Inline Entity Form. This is a short comparison of the two modules.
Acquia: Automatic Module Upgrader for Drupal 8 getting some love!
Back in February at the Acquia Build Week hackathon, Team "Upgrade Roboto" (webchick, Wim Leers, Gábor Hojtsy, xjm, japerry, and estha) published the Drupal Module Upgrader project.
Zivtech: Philly Dev Camp, an Instructor's Perspective
Acquia: Commons Team Improving Contrib & Core
As part of our day-to-day maintenance of Drupal Commons, we often assist with Drupal contributed modules that are included as part of Commons but not specific to the application, whether that means fixing bugs by writing or reviewing patches, or coordinating with other module maintainers and the Drupal Security team to help reduce the time between reported issues and security advisories.
Mediacurrent: How Drupal is making a difference in South Los Angeles
In the fall of 2012 while doing a talk at a local conference in Los Angeles I was approached by Oscar Menjivar, founder and CEO of Teens eXploring Technology (TxT), a non-profit organization teaching inner city teenagers from South Los Angeles about technology and leadership. Oscar was looking into Drupal as a potential technology to include in the summer coding academy his organization holds every year.
Acquia: Why should I go to DrupalCon? - Rebroadcast - The benefits of being there
With DrupalCon Amsterdam and The Prenote right around the corner, it seemed like a good time to revisit this recording from when I had the tables turned on me at DrupalCon Portland and got interviewed by Ray Saltini from Blink Reaction. He asked me some great questions about Drupal, and especially why you should come to Drupal community events like DrupalCon. See you in Amsterdam!
Dries Buytaert: Amazon invests in Acquia
I'm happy to share news that Amazon has joined the Acquia family as our newest investor. This investment builds on the recent $50 million financing round that Acquia completed in May, which was led by New Enterprise Associates (NEA).
Acquia is the largest provider of Drupal infrastructure in the world. We run on more than 8,000 AWS instances and serve more than 27 billion hits a month or 333 TB of bandwidth a month. Working with AWS has been an invaluable part of our success story, and today's investment will further solidify our collaboration.
We did not disclose the amount of the investment in today's news announcement.
Appnovation Technologies: How to Enable Disqus On Drupal
var switchTo5x = false;stLight.options({"publisher":"dr-75626d0b-d9b4-2fdb-6d29-1a20f61d683"}); Drupal Association News: Get Involved: Volunteer at OSCON and more
What do you get when you bring together thousands of diverse open source developers in Portland, Oregon? Great parties with delicious craft beer! But you also get Linux kernel hackers mingling with Docker devops engineers who are talking with PHP and Perl developers. Great minds from across the world learn from each other to make open source even better at OSCON, the annual open source conference.
This year, 16 amazing volunteers helped represent Drupal to over 4,200 open source developers at the annual OSCON trade show. At the Drupal Association booth, volunteers handed out Drupal stickers, shared how Drupal can be the solution to a broad range of web needs, and talked about the extensive contrib project ecosystem and active Drupal community. Our helpful volunteers also answered a lot of questions ranging from "What is Drupal and how much does it cost?" to "When is Drupal 8 going to be released?"
OSCON will return next year, July 20-24, and we'd love to have you join us to spread the joy of Drupal. To get involved with spreading the word, get in touch the Drupal Association via their contact form or through Twitter.
Having a great time at the Drupal booth at #OSCON. Stop by, grab a sticker and say hello! pic.twitter.com/Iyla5RdyQk
— Drupal Association (@DrupalAssoc) July 23, 2014InternetDevels: Drupalaton 2014 — dive into Drupal 8!
Our web development army continues its reconnaissance operations on the best DrupalCamp events! August 7-10 we have taken one more strategic point — Hungarian Drupalaton!
A world-wide famous Balaton lake has become a location for one of the biggest Drupal venues in Hungary. InternetDevels company has supplied this event by becoming its silver sponsor!
The participants had no chance for boredom — workshops and code sprints were supported by wonderful launch-breaks and exciting leisure time activities!
Read moreTrellon.com: Portable Configuration in Drupal
The Drupal community is hard at work delivering the next major release, Drupal 8. If you are already involved, your help is much appreciated. If not, but you would like to help with Drupal core development anre are looking for a way to start, take a look at core mentoring hours. It's a great way for people to get involved, and there are several time slots each week that suit many people's schedules.
Drupal.org Featured Case Studies: MIT List Visual Arts Center
Completed Drupal site or project URL: http://listart.mit.edu/MIT's List Visual Arts Center is the contemporary art museum and visual art lab at the Massachusetts Institute of Technology in Cambridge. After completing a comprehensive rebrand of the List, we set out to bring that brand to life online. TOKY — the team behind the site's design and development — is a full-service branding and design consultancy with offices in St. Louis, Chicago, and Boston.
Key modules/theme/distribution used: Advanced CSS/JS AggregationAutomatic NodetitlesConstant ContactDateEntity referenceField collectionGeolocation FieldGoogle Site SearchImageAPI Optimize (or Image Optimize)MediaMediaElementRemote stream wrapperSub-pathauto (Sub-path URL Aliases)TypogrifyOrganizations involved: TOKY Branding + DesignTeam members: Daniel KortePedro Rocha: Split Views filters and sort options in different blocks with Drupal
MariqueCalcus: Our first Drupal 8 theme get updated
Today we are excited to announce the latest release of our Drupal 8 theme Prius. The last build support the freshly baked (Drupal 8 Alpha 14). The migration from alpha13 to alpha14 was pretty smooth. We just run into some weird issues that we've traced down to the libraries implementation. We'll explain how we fixed it to prevent you from some Drupal headaches.
Check out the code on drupal.org or read our dedicated blog entry if you want to find out more about our first Drupal 8 theme.
Read More...Propeople Blog: How We Use Vagrant In Our Drupal Development Workflow
A lot of Drupal companies have started adopting virtual development environments. This has a lot of benefits for unifying the way people collaborate on projects. The main idea behind it is to have everyone working on the same environment, following the same production set up. Using a virtual environment, you can standardize what versions of PHP, MySQL, Apache, Nginx, Memcache, Varnish, Solr, Sass/Compass libraries, etc. are used. This way, you do not have to worry about things like setting up your front-end developer on their Mac, Windows, or Linux machine with a bunch of software for a particular project. In this article I would like to share some thoughts on how we at Propeople utilize Vagrant, an open-source software that we use to create virtual development environments.
Starting point
When we start a Drupal project, we do not just keep the Drupal codebase in the repo. We also keep configuration files of Vagrant and the Drupal repo. We use configurations from puphpet.com as a starting point but add some customizations on top. Based on our production set up (version of operating system, web server, PHP versions) we generate configs and then adjust them to our needs. One example of such a code structure can be seen at https://github.com/podarok/ppdorg. Here is the basic structure:
IP address and tools
We use a virtual host for the project. For example, after bringing up the virtual machine, we can use the URL http://ppdorg.192.168.56.112.xip.io to access our development site. We use the xip.io service for building host names. In some projects, we also put a custom index.html so when you open http://192.168.56.112.xip.io you will see the list of tools available for the site builder.
Tools
We usually set up tools like Adminer.php, phpinfo.php and some others for developers. One of the regularly used scripts we include is a reinstall of the site (we build our sites as installation profiles) and pull_stage.sh – a script to pull the database and files from the staging or live environments.
Pull from staging
On Vagrant Box we install Drush and use it for syncing of the database and files from the remote environment. In order to have SSH login to that environment, we also copy the SSH keys to vagrant box. This can be done by adjusting the puphpet/shell/ssh-keyget.sh script by adding the following to the end of the script:
echo "Copy box ssh keys to ${VAGRANT_SSH_FOLDER}"
cp ${VAGRANT_CORE_FOLDER}/files/dot/ssh/box_keys/* ${VAGRANT_SSH_FOLDER}/
chown "${VAGRANT_SSH_USERNAME}" "${VAGRANT_SSH_FOLDER}/id_rsa"
chown "${VAGRANT_SSH_USERNAME}" "${VAGRANT_SSH_FOLDER}/id_rsa.pub"
chgrp "${VAGRANT_SSH_USERNAME}" "${VAGRANT_SSH_FOLDER}/id_rsa"
chgrp "${VAGRANT_SSH_USERNAME}" "${VAGRANT_SSH_FOLDER}/id_rsa.pub"
chmod 600 ${VAGRANT_SSH_FOLDER}/*
We generate keys, placing them in puphpet/files/dot/ssh/box_keys. Then we add the public key to our staging server and that is it. It is possible to “Vagrant SSH” to the box and then run the script to keep your database and files up to date.
When we pull a database from staging we, of course, sanitize email addresses and adjust settings (for example, switching to Sandbox environments of third party systems that we integrate with, etc.).
Drupal's settings.php file
On the Drupal side, we also create a sites/default/dev_settings.php file with all the settings for the database, memcache and any other parameters needed for development. So the only thing developers need to do is to copy this file to settings.php and run the reinstall.sh script to set the site up.
Configuration changes
Let’s say we have added memcache to the project, or Apache Solr. The only thing that we need to do is to commit the Vagrant configuration changes to the repo and ask everyone to run “vagrant provision”. Doing this will set everyone's environment to the current state. This is why we love Vagrant and see the benefits of using it every day.
Downsides of Using Vagrant
We need to have enough RAM. Usually we assign 1Gb for each box. Preferably, a development machine should have 8Gb of RAM because some of our projects have multiple boxes. Another preferable thing is having SSD. What this means is that if you have pretty decent laptop, you should have everything in place to try Vagrant out.
Conclusion
We find using Vagrant to be extremely effective. It allows our teams to work together more efficiently to deliver some of the biggest, most complex Drupal projects in the industry. Adopting a virtual development environment has had a positive effect on our development workflow, getting rid of past pressure points in our process. To learn more about how we can help your Drupal project succeed, please contact us.
Tags: VagrantDrupalDevelopmentService category: TechnologyCheck this option to include this post in Planet Drupal aggregator: planetTopics: Tech & DevelopmentStanford Web Services Blog: How I learned the hard way to create reusable classes
Drupal is (in)famous for providing an egregious amount of class selectors to target every layer imaginable in its rendered HTML. Some superstar culprits are Field Collections, Field Groups, and complex Views. When we see so many handy, available selector classes, it's so tempting just to target them directly in your CSS. But today, I want to share a lesson I learned the hard way about why you've just gotta resist that temptation, and instead create reusable classes.
Trellon.com: Avoiding Sass Version Differences with Bundler
If you are doing a lot of theming in Drupal with Sass and Compass, there's a good chance your stylesheets rely on specific versions of gems to compile properly. Mixins and functions can change, and sometimes gems rely on specific versions of other gems to work properly.
