Feed aggregator

Craig Aschbrenner: Email fields missing feature? Email Confirmation!

Planet Drupal - Thu, 14/08/2014 - 05:50

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!

Features

At 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.
Beta Release

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.

Categories: Elsewhere

Paul Rowell: Repeatable fieldsets in Drupal: Inline Entity Form Vs Field Collection

Planet Drupal - Thu, 14/08/2014 - 00:47

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.

Categories: Elsewhere

Acquia: Automatic Module Upgrader for Drupal 8 getting some love!

Planet Drupal - Wed, 13/08/2014 - 23:34

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.

Categories: Elsewhere

Zivtech: Philly Dev Camp, an Instructor's Perspective

Planet Drupal - Wed, 13/08/2014 - 22:43
Earlier this year Zivtech received a Startup PHL "call for ideas grant" from the city of Philadelphia. The project’s goal was to help teach aspiring students or recent graduates today’s top web development technologies and help sculpt the technical landscape of the city. With help from Neomind Labs we have set out to help change the future for 24 students, or devcampers as I like to call them, at the first Philly Dev Camp. Philly Dev Camp is a web developer boot camp focusing on skills that local tech companies are looking for in today's workforce.   I have been an instructor with Zivtech for about a year now, and this is one of the larger--if not largest--classes I have taught. As the instructors, we did not get to learn much about the students before Philly Dev Camp started, but David Hamme, Neomind's Alex Kaplan, and Zivtech President/CTO Jody Hamilton, did great job of choosing the right devcampers for the inaugural 2014 camp. We have been collecting a ton of feedback about the camp so far, and things seem to be going really well from what we have gathered. We probably have a few things to work on, but it's a first for everyone this year. We are hoping with the outcome of this year’s camp we can continue working with the city to provide technical education to Greater Philly Area residents and keep the camp going.   Devcampers have already completed 4 weeks out of the 5 weeks of this year’s class. Students have learned a handful of crucial skills so far such as command line basics, the LAMP stack, git for version control, and SASS for front-end development. Many students came into this class just knowing some HTML and CSS, while others have already built their own sites using Wordpress, so the skill levels are varied throughout the class. The most notable characteristic to me about this class is that those that are more advanced are eager to help their less-experienced peers. This means that they are going to work well on teams with multiple developers in the future.   I am only one of the handful of instructors that Zivtech has brought to the table for Philly Dev Camp. Our other 2014 Philly Dev Camp instructors are Jody Hamilton, Sean Wolfe, and Howard Tyson. Each of us was tasked to cover our strongest skillsets. I covered git, MySQL, and Drupal Site Building. Jody has covered command line basics, vim, PHP basics, and advanced Drupal site building and Drupal development. Sean has covered CSS and SASS front end development, and Drupal theming. At the end of last week, Howard started taking the devcampers on a hike through hot new web technologies like Angular.js, Node.js, and newer database systems like MondoDB, redis, and memcache. This week students have been getting a full helping of Ruby on Rails training by Ryan Findley and John Parsons from Neomind Labs. Outside of our instructor team, we have also had some additional help from Zivtech team members Victor Lourng and James Jones.   I had always wanted to be a teacher, so being able to help the students of Philly Dev Camp learn something I enjoy doing, and is a very useful skillset for their future, is a very rewarding feeling. It will be interesting to see how things shape up for the remaining 3 weeks of Philly Dev Camp and where these new skills will take them after the class is over. I’m looking forward to this becoming a yearly thing that we can continue for a long time to help build up Philadephia as a major contributor to shaping tomorrow's web.   Follow Phillly Dev Camp on Twitter at @phillydevcamp. Terms: PhillyDevCampWeb Developer BootcampPDC14NeomindDrupal Planet
Categories: Elsewhere

Acquia: Commons Team Improving Contrib & Core

Planet Drupal - Wed, 13/08/2014 - 22:34

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.

Categories: Elsewhere

Mediacurrent: How Drupal is making a difference in South Los Angeles

Planet Drupal - Wed, 13/08/2014 - 22:22

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.

Categories: Elsewhere

Ian Donnelly: The New Deal: ucf Integration

Planet Debian - Wed, 13/08/2014 - 21:29

Hi Everybody,

A few days ago I posted an entry on this blog called dpkg Woes where I explained that due to a lack of response, we were abandoning our plan to patch dpkg for my Google Summer of Code project, and I explained that we had a new solution. Well today I would like to tell you about that solution. Instead of patching dpkg, which would take a long time and seemed like it would never make it upstream, we have added some new features to ucf which will allow my Google Summer of Code project to be realized.

If you don’t know, ucf, which stands for Update Configuration File, is a popular Debian package whose goal is to “preserve user changes to config files.” It is meant to act as an alternative to considering a configuration file a conffile on systems that use dpkg. Instead, package maintainers can use ucf to handle these files in a conffile-like way. Where conffiles must work on all systems, because they are shipped with the package, configuration files that use ucf can be handled by maintainer scripts and can vary between systems. ucf exists as a script that allows conffile-like handling of non-conffile configuration files and allows much more flexibility than dpkg’s conffile system. In fact, ucf even includes an option to perform a three-way merge on files it manages, it currently only uses diff3 for the task though.

As you can see, ucf has a goal that while different than ours, seems naturally compatible to our goal of automatic conffile merging. Obviously, since ucf is a different tool than dpkg we had to re-think how we were going to integrate with ucf. Luckily, integration with ucf proved to be much more simple than integration with dpkg. All we had to do to integrate with ucf was to add a generic hook to attempt a three way merge using any tool created for the task such as Elektra and kdb merge. Felix submitted a pull request with the exact code almost a week ago and we have talked with Manoj Srivastava, the developer for ucf, and he seemed to really like the idea. The only changes we made are to add an option for a three-way merge command, and if one is present, the merge is attempted using the specified command. It’s all pretty simple really.

Now, package maintainers can edit their scripts to utilize this new feature. If they want, package maintainers can specify a command to use to merge files using ucf during package upgrades. I will soon be posting a tutorial about how to integrate this feature into a package and how to use Elektra in your scripts in order to allow for automatic three-way merges during package upgrade. I will post a link to the tutorial here once it is published.

Sincerely,
Ian S. Donnelly

Categories: Elsewhere

Richard Hartmann: Slave New World

Planet Debian - Wed, 13/08/2014 - 20:39

Ubiquitous surveillance is a given these days, and I am not commenting on the crime or the level of stupidity of the murderer, but the fact that the iPhone even logs when you turn your flashlight on and off is scary.

Very, very scary in all its myriad of implications.

But at least it's not as if both your phone and your carrier wouldn't log your every move anyway.

Because Enhanced 911 and its ability to silently tell the authorities your position was not enough :)

Categories: Elsewhere

Daniel Pocock: WebRTC in CRM/ERP solutions at xTupleCon 2014

Planet Debian - Wed, 13/08/2014 - 20:29

In October this year I'll be visiting the US and Canada for some conferences and a wedding. The first event will be xTupleCon 2014 in Norfolk, Virginia. xTuple make the popular open source accounting and CRM suite PostBooks. The event kicks off with a keynote from Apple co-founder Steve Wozniak on the evening of October 14. On October 16 I'll be making a presentation about how JSCommunicator makes it easy to add click-to-call real-time communications (RTC) to any other web-based product without requiring any browser plugins or third party softphones.

Juliana Louback has been busy extending JSCommunicator as part of her Google Summer of Code project. When finished, we hope to quickly roll out the latest version of JSCommunicator to other sites including rtc.debian.org, the WebRTC portal for the Debian Developer community. Juliana has also started working on wrapping JSCommunicator into a module for the new xTuple / PostBooks web-based CRM. Versatility is one of the main goals of the JSCommunicator project and it will be exciting to demonstrate this in action at xTupleCon.

xTupleCon discounts for developers

xTuple has advised that they will offer a discount to other open source developers and contributers who wish to attend any part of their event. For details, please contact xTuple directly through this form. Please note it is getting close to their deadline for registration and discounted hotel bookings.

Potential WebRTC / JavaScript meet-up in Norfolk area

For those who don't or can't attend xTupleCon there has been some informal discussion about a small WebRTC-hacking event at some time on 15 or 16 October. Please email me privately if you may be interested.

Categories: Elsewhere

Acquia: Why should I go to DrupalCon? - Rebroadcast - The benefits of being there

Planet Drupal - Wed, 13/08/2014 - 19:27

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!

Categories: Elsewhere

Dries Buytaert: Amazon invests in Acquia

Planet Drupal - Wed, 13/08/2014 - 17:46
Topic: AcquiaDrupal

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.

Categories: Elsewhere

Appnovation Technologies: How to Enable Disqus On Drupal

Planet Drupal - Wed, 13/08/2014 - 17:15
This will be a quick tutorial on how to set up Disqus on a Drupal site for commenting. var switchTo5x = false;stLight.options({"publisher":"dr-75626d0b-d9b4-2fdb-6d29-1a20f61d683"});
Categories: Elsewhere

Drupal Association News: Get Involved: Volunteer at OSCON and more

Planet Drupal - Wed, 13/08/2014 - 17:00

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, 2014
Categories: Elsewhere

InternetDevels: Drupalaton 2014 — dive into Drupal 8!

Planet Drupal - Wed, 13/08/2014 - 16:45

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 more
Categories: Elsewhere

Riku Voipio: Booting Linaro ARMv8 OE images with Qemu

Planet Debian - Wed, 13/08/2014 - 16:36
A quick update - Linaro ARMv8 OpenEmbbeded images work just fine with qemu 2.1 as well:
$ http://releases.linaro.org/14.07/openembedded/aarch64/Image
$ http://releases.linaro.org/14.07/openembedded/aarch64/vexpress64-openembedded_lamp-armv8-gcc-4.9_20140727-682.img.gz
$ qemu-system-aarch64 -m 1024 -cpu cortex-a57 -nographic -machine virt \
-kernel Image -append 'root=/dev/vda2 rw rootwait mem=1024M console=ttyAMA0,38400n8' \
-drive if=none,id=image,file=vexpress64-openembedded_lamp-armv8-gcc-4.9_20140727-682.img \
-netdev user,id=user0 -device virtio-net-device,netdev=user0 -device virtio-blk-device,drive=image
[ 0.000000] Linux version 3.16.0-1-linaro-vexpress64 (buildslave@x86-64-07) (gcc version 4.8.3 20140401 (prerelease) (crosstool-NG linaro-1.13.1-4.8-2014.04 - Linaro GCC 4.8-2014.04) ) #1ubuntu1~ci+140726114341 SMP PREEMPT Sat Jul 26 11:44:27 UTC 20
[ 0.000000] CPU: AArch64 Processor [411fd070] revision 0
...
root@genericarmv8:~#
Quick benchmarking with age-old ByteMark nbench: Index Qemu Foundation Host Memory 4.294 0.712 44.534 Integer 6.270 0.686 41.983 Float 1.463 1.065 59.528Baseline (LINUX) : AMD K6/233* Qemu is upto 8x faster than Foundation model on Integers, but only 50% faster on Math. Meanwhile, the Host pc spends 7-40x slower emulating ARMv8 than executing native instructions.
Categories: Elsewhere

Trellon.com: Portable Configuration in Drupal

Planet Drupal - Wed, 13/08/2014 - 16:06

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.

Categories: Elsewhere

Drupal.org Featured Case Studies: MIT List Visual Arts Center

Planet Drupal - Wed, 13/08/2014 - 14:30
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 Korte
Categories: Elsewhere

Pedro Rocha: Split Views filters and sort options in different blocks with Drupal

Planet Drupal - Wed, 13/08/2014 - 09:02
When i found that exposing the Views filters as a block, to use as a search block for a Search API page, would show the sort options together, i thought: "Oh sh**". I instantly thought that it would be painful to get a "specific use case" like this one working quick. But i'm working with Drupal, right? hehe In 3 steps, the solution was simple, by the community:
Categories: Elsewhere

MariqueCalcus: Our first Drupal 8 theme get updated

Planet Drupal - Wed, 13/08/2014 - 00:34

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...
Categories: Elsewhere

Ian Donnelly: How-To: kdb import

Planet Debian - Tue, 12/08/2014 - 22:29

Hi everybody,

Today I wanted to go over what I think is a very useful command in the kdb tool, kdb import. As you know, the kdb tool allows users to interact with the Elektra Key Database (KDB) via the command line. Today I would like to explain the import function of kdb.

The command to use kdb import is:

kdb import [options] destination [format]

In this command, destination is where the imported Keys should be stored below. For instance, kdb import system/imported would store all the keys below system/imported. This command takes Keys from stdin to store them into KDB. Typically, this command is used with a pipe to read in the Keys from a file.

The format argument you see above can be a very powerful option to use with kdb import. The format argument allows a user to specify which plug-in is used to import the Keys into the Key Database. The user can specify any storage plug-in to serve as the format for the Keys to be imported. For instance, if a user wanted to import a /etc/hosts file into KDB without mounting it, they could use the command cat /etc/hosts | kdb import system/hosts hosts. This command would essentially copy the current hosts file into KDB, like mounting it. Unlike mounting it, changes to the Keys would not be reflected in the hosts file and vise versa.

If no format is specified, the format dump will be used instead. The dump format is the standard way of expressing Keys and all their relevant information. This format is intended to be used only within Elektra. The dump format is a good means of backing up Keys from the Key Database for use with Elektra later such as reimporting them later. As of this writing, dump is the only way to fully preserve all parts of the KeySet.

It is very important to note that the dump does not rename keys by design. If a user exports a KeySet using dump using a command such as kdb export system/backup > backup.ecf, they can only import that keyset back into system/backup using a command like cat backup.ecf | kdb import system/backup.

The kdb import command only takes one special option:

-s --strategy

which is used to specify a strategy to use if Keys already exist in the specified destination.
The current list of strategies are:

preserve any keys already in the destination will not be overwritten
overwrite any keys already in the destination will be overwritten if a new key has the same name
cut all keys already in the destination will be removed, then new keys will be imported

If no strategy is specified, the command defaults to the preserve strategy as to not be destructive to any previous keys.

An example of using the kdb import is as follows:

cat backup.ecf | kdb import system/restore

This command would import all keys stored in the file backup.ecf into the Key Database under system/restore.

In this example, backup.ecf was exported from the KeySet using the dump format by using the command:
kdb export system/backup > backup.ecf

backup.ecf contains all the information about the keys below system/backup:

$cat backup.ecf
kdbOpen 1
ksNew 3
keyNew 19 0
system/backup/key1
keyMeta 7 1
binary
keyEnd
keyNew 19 0
system/backup/key2
keyMeta 7 1
binary
keyEnd
keyNew 19 0
system/backup/key3
keyMeta 7 1
binary
keyEnd
ksEnd

Before the import command, system/backup does not exists and no keys are contained there.
After the import command, running the command kdb ls system/backup prints:

system/backup/key1
system/backup/key2
system/backup/key3

As you can see, the kdb import command is a very useful tool included as part of Elektra. I also wrote a tutorial on the kdb export command. Please go read that as well because those two commands go hand in hand and allow some very powerful usage of Elektra.

Sincerely,
Ian S. Donnelly

Categories: Elsewhere

Pages

Subscribe to jfhovinne aggregator