Planet Drupal

Syndicate content
Drupal.org - aggregated feeds in category Planet Drupal
Updated: 42 min 10 sec ago

Erik Erskine: Nicer date ranges in Drupal – part 3

Mon, 06/05/2017 - 01:00
pThis is the last part of a series on improving the way date ranges are presented in Drupal, by creating a field formatter that can omit the day, month or year where appropriate, displaying the date ranges in a nicer, more compact form:/pullistrong24ndash;25 January 2017/strong/lilistrong29 Januaryndash;3 February 2017/strong/lilistrong9:00amndash;4:30pm, 1 April 2017/strong/li/ulpIn this post we look at adding an administrative interface, so site builders can add and edit formats from Drupal's UI./p pa href=https://www.erskine.uk/blog/2017/drupal-date-ranges-3Read more/a/p

OSTraining: Creating Printer-friendly Versions of Drupal Articles

Mon, 06/05/2017 - 01:00
div class=ost-intro-imageimg src=https://www.ostraining.com/images/drupal/printer-friendly-versions-drupal.jpg alt=Creating Printer-friendly Versions of Drupal Articles width=200 height=133 //div pIn this tutorial, we'll show you how to add a Printer-friendly version button to your Drupal articles. The main reason you'd want to do this is a courtesy for your readers. Many still print things they read online and you don't want them to waste that expensive printer ink just to print your logo and theme as well as the article./p pThis is a themed tutorial because our sister post a href=https://www.ostraining.com/index.php?option=com_contentamp;view=articleamp;id=837:printer-friendly-versions-wordpressamp;catid=31amp;Itemid=300247Creating Printer-friendly Versions of Wordpress Posts/a with Wordpress tutorial covers the same topic./p pWithout this solution, you'd likely need to create a separate CSS file with styles specifically for the printed page.nbsp; Fortunately, the Printer, email and PDF versions Drupal community module makes this much easier. It will automatically create a printer-friendly version of each article./p

Matt Glaman: Swapping Drupal 8 services to customize Drupal Commerce

Sun, 06/04/2017 - 18:11
div class=field-body pOne of the reasons that I love Drupal 8 is the fact it is object orientated and uses the Dependency Injection pattern with a centralized service container. If you’re new to the concept, here’s some links for some fun reading./p ul lia href=https://en.wikipedia.org/wiki/Dependency_injectionhttps://en.wikipedia.org/wiki/Dependency_injection/a/li lia href=http://www.jamesshore.com/Blog/Dependency-Injection-Demystified.htmlhttp://www.jamesshore.com/Blog/Dependency-Injection-Demystified.html/a/li lia href=https://martinfowler.com/articles/injection.htmlhttps://martinfowler.com/articles/injection.html/a/li /ul pBut for now the basics are: Things define their dependencies, and a centralized thing is able to give you an object instance with all of those dependencies provided. You don’t need to manually construct a class and provide its dependencies (constructor arguments.)/p pThis also means we do not have to use concrete classes! That means you can modify the class used for a service without ripping apart other code. Yay for being decoupled(ish)!/p h2Why is this cool?/h2 pSo that’s great, and all. But let’s actually use a real example to show how strongAWESOME/strong this is. In Drupal Commerce we have the codecommerce_cart.cart_session/code service. This is how we know if an anonymous user has a cart or not. We assume this service will implement the code\Drupal\commerce_cart\CartSessionInterface/code interface, which means we don’t care how you tell us, just tell us via our agreed methods./p pThe default class uses the native session handling. But we’re going to swap that out and use cookies instead. Why? Because skipping the session will preserve page cache while browsing the site catalogs and product pages./p h2Let’s do it/h2 pLet’s kick it off by creating a module called codecommerce_cart_cookies/code. This will swap out the existing codecommerce_cart.cart_session/code service to use our own implementation which relies on cookies instead of the PHP session./p pThe obvious: we need a codecommerce_cart_cookies.info.yml/code/p div class=codeblock nowrap-expandcodenbsp;nbsp;nbsp; name: Commerce Cart Cookiesbr /nbsp;nbsp;nbsp; description: Uses cookies for cart session instead of PHP sessionsbr /nbsp;nbsp;nbsp; core: 8.xbr /nbsp;nbsp;nbsp; type: modulebr /nbsp;nbsp;nbsp; dependencies:br /nbsp;nbsp;nbsp; - commerce_cart/code/div pNow we need to create our class which will replace the default session handling. I’m not going to go into what the entire code would look like to satisfy the class, but the generic class would resemble the following. You can find a repo for this project at the end of the article./p div class=codeblock nowrap-expandcodenbsp;nbsp;nbsp; lt;?phpbr /br /namespace Drupal\commerce_cart_cookies;br /br /use Drupal\commerce_cart\CartSessionInterface;br /use Symfony\Component\HttpFoundation\RequestStack;br /br //**br / * Uses cookies to track active carts.br / *br / * We inject the request stack to handle cookies within the Request object,br / * and not directly.br / */br /class CookieCartSession implements CartSessionInterface {br /br /nbsp; /**br /nbsp;nbsp; * The current request.br /nbsp;nbsp; *br /nbsp;nbsp; * a href=http://twitter.com/var class=twitter-atreply@var/a \Symfony\Component\HttpFoundation\Requestbr /nbsp;nbsp; */br /nbsp; protected $request;br /br /nbsp; /**br /nbsp;nbsp; * Creates a new CookieCartSession object.br /nbsp;nbsp; *br /nbsp;nbsp; * a href=http://twitter.com/param class=twitter-atreply@param/a \Symfony\Component\HttpFoundation\RequestStack $request_stackbr /nbsp;nbsp; *nbsp;nbsp; The request stack.br /nbsp;nbsp; */br /nbsp; public function __construct(RequestStack $request_stack) {br /nbsp;nbsp;nbsp; $this-gt;request = $request_stack-gt;getCurrentRequest();br /nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp; /**br /nbsp;nbsp;nbsp; * {a href=http://twitter.com/inheritdoc class=twitter-atreply@inheritdoc/a}br /nbsp;nbsp;nbsp; */br /nbsp;nbsp;nbsp; public function getCartIds($type = self::ACTIVE) {br /nbsp;nbsp;nbsp; // TODO: Implement getCartIds() method.br /nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp; /**br /nbsp;nbsp;nbsp; * {a href=http://twitter.com/inheritdoc class=twitter-atreply@inheritdoc/a}br /nbsp;nbsp;nbsp; */br /nbsp;nbsp;nbsp; public function addCartId($cart_id, $type = self::ACTIVE) {br /nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp; /**br /nbsp;nbsp;nbsp; * {a href=http://twitter.com/inheritdoc class=twitter-atreply@inheritdoc/a}br /nbsp;nbsp;nbsp; */br /nbsp;nbsp;nbsp; public function hasCartId($cart_id, $type = self::ACTIVE) {br /nbsp;nbsp;nbsp; // TODO: Implement hasCartId() method.br /nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp; /**br /nbsp;nbsp;nbsp; * {a href=http://twitter.com/inheritdoc class=twitter-atreply@inheritdoc/a}br /nbsp;nbsp;nbsp; */br /nbsp;nbsp;nbsp; public function deleteCartId($cart_id, $type = self::ACTIVE) {br /nbsp;nbsp;nbsp; // TODO: Implement hasCartId() method.br /nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp; }/code/div pNext we’re going to make our service provider class. This is a bit magical, as we do not actually register it anywhere. It just needs to exist. Drupal will look for classes that end in ServiceProvider within all enabled modules. Based on the implementation you can add or alter services registered in the service container when it is being compiled (which is why the process is called rebuild! not just cache clear in Drupal 8.) The class must also start with a camel cased version of your module name. So our class will be codeCommerceCartCookiesServiceProvider/code./p pCreate a src directory in your module and a codeCommerceCartCookiesServiceProvider.php/code file within it. Let’s scaffold out the bare minimum for our class./p div class=codeblock nowrap-expandcodenbsp;nbsp;nbsp; lt;?phpbr /br /namespace Drupal\commerce_cart_cookies;br /br /use Drupal\Core\DependencyInjection\ServiceProviderBase;br /br /class CommerceCartCookiesServiceProvider extends ServiceProviderBase { }/code/div pLuckily for us all, core provides code\Drupal\Core\DependencyInjection\ServiceProviderBase/code for us. This base class implements codeServiceProviderInterface/code and codeServiceModifierInterface/code to make it easier for us to modify the container. Let’s override the alter method so we can prepare to modify the codecommerce_cart.cart_session/code service./p div class=codeblock nowrap-expandcodenbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; lt;?phpbr /br /namespace Drupal\commerce_cart_cookies;br /br /use Drupal\Core\DependencyInjection\ContainerBuilder;br /use Drupal\Core\DependencyInjection\ServiceProviderBase;br /br /class CommerceCartCookiesServiceProvider extends ServiceProviderBase {br /br /nbsp; /**br /nbsp;nbsp; * {a href=http://twitter.com/inheritdoc class=twitter-atreply@inheritdoc/a}br /nbsp;nbsp; */br /nbsp; public function alter(ContainerBuilder $container) {br /nbsp;nbsp;nbsp; if ($container-gt;hasDefinition(#039;commerce_cart.cart_session#039;)) {br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; $container-gt;getDefinition(#039;commerce_cart.cart_session#039;)br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; -gt;setClass(CookieCartSession::class)br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; -gt;setArguments([new Reference(#039;request_stack#039;)]);br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; }br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; }br /br /nbsp;nbsp;nbsp;nbsp;nbsp;nbsp;nbsp; }br /nbsp;nbsp;nbsp; /code/div pWe update the definition for commerce_cart.cart_session to use our class name, and also change it’s arguments to reflect our dependency on the request stack. The default service injects the session handler, whereas we need the request stack so we can retrieve cookies off of the current request./p pThe cart session service will now use our provided when the container is rebuilt!/p pThe project code can be found at a href=https://github.com/mglaman/commerce_cart_cookieshttps://github.com/mglaman/commerce_cart_cookies/a/p /div

Drupal core announcements: Drupal 8 and 7 core release window on Wednesday, June 07, 2017

Sat, 06/03/2017 - 16:10
div class=field field-type-datestamp field-field-start7 div class=field-items div class=field-item odd div class=field-label-inline-first Start:nbsp;/div span class=date-display-start2017-06-06 12:00/spanspan class=date-display-separator - /spanspan class=date-display-end2017-06-08 12:00 UTC/span /div /div /div div class=field field-type-userreference field-field-organizers div class=field-labelOrganizers:nbsp;/div div class=field-items div class=field-item odd catch /div div class=field-item even cilefen /div div class=field-item odd David_Rothstein /div div class=field-item even Fabianx /div div class=field-item odd stefan.r /div div class=field-item even xjm /div /div /div div class=field field-type-text field-field-event-type div class=field-labelEvent type:nbsp;/div div class=field-items div class=field-item odd Online meeting (eg. IRC meeting) /div /div /div pThe monthly core patch (bug fix) release window is this Wednesday, June 07. Drupal 8.3.3 and 7.55 will be released with fixes for Drupal 8 and 7./p pTo ensure a reliable release window for the patch release, there will be a Drupal 8.3.x commit freeze from 12:00 UTC Tuesday to 12:00 UTC Thursday. Now is a good time to update your development/staging servers to the latest 8.3.x-dev or 7.x-dev code and help us catch any regressions in advance. If you do find any regressions, please report them in the a href=https://www.drupal.org/project/issues/search/drupal?project_issue_followers=amp;status%5B%5D=Openamp;version%5B%5D=8.xamp;version%5B%5D=7.xamp;issue_tags_op=%3Dissue queue/a. Thanks!/p pTo see all of the latest changes that will be included in the releases, see the a href=http://cgit.drupalcode.org/drupal/log/8.3.x commit log/a and a href=http://cgit.drupalcode.org/drupal/log/?h=7.x7.x commit log/a./p pOther upcoming core release windows after this week include:/p ulliWednesday, June 21 (security release window)/li liWednesday, July 05 (patch release window)/li liWednesday, October 5 (scheduled minor release)/li /ulpFor more information on Drupal core release windows, see the documentation on a href=http://drupal.org/documentation/version-info#whenrelease timing/a and a href=http://drupal.org/node/1173280security releases/a, as well as the a href=https://www.drupal.org/core/release-cycle-overviewDrupal core release cycle overview/a./p

Drupal Commerce: Installing Commerce 2.x without Composer, with Ludwig

Fri, 06/02/2017 - 19:40
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpThe average Drupal Commerce site depends on many external PHP libraries. Address needs a href=https://github.com/commerceguys/addressingcommerceguys/addressing/a and Commerce needs a href=https://github.com/commerceguys/intcommerceguys/intl/a. GeoIP needs a href=https://github.com/maxmind/GeoIP2-phpgeoip2/geoip2/a and Search API Solr needs a href=https://github.com/solariumphp/solariumsolarium/solarium/a. Each payment gateway needs a matching SDK. These libraries must be downloaded separately, because license constraints prevent us from committing their code to drupal.org itself. For the past 5 years, the primary and only way to download and use PHP libraries has been a href=https://getcomposer.org/Composer/a, a command line tool./p pComposer works per-project, meaning each Drupal install has one folder for all PHP libraries it requires, regardless of which module needs which. This allows Composer to detect and prevent conflicts such as incompatible library versions. Composer also recursively resolves dependencies, automatically installing and updating packages required by other packages. This is a emmajor/em benefit to Drupal site administrators compared to previous tools like Drush Make. However, Drupal's reliance on the Composer-generated autoloader makes it impossible to upload manually downloaded libraries, making Composer non-optional./p pa href=https://drupalcommerce.org/blog/49669/installing-commerce-2x-without-composer-ludwigRead on to find out how we're making Composer optional.../a/p /div/div/div

Drupal @ Penn State: Building a #Polymer App for the web, then #Drupal

Fri, 06/02/2017 - 19:04
pAs twitter, other social networks, conference submissions and drupal planet posts would suggest; I’m a bit over the moon about a href=https://www.polymer-project.org/Polymer/a for a href=https://www.webcomponents.org/Web Components/a. I’ve avoided front-end development workflows for years because they made no sense to me. Lots of custom bailing wire that would make a slick (but completely un-reusable) one-page-app. Nay said I! I will strongnever/strong do front end development!/p

Lullabot: Drupal Governance with Megan Sanicki and Whitney Hess

Fri, 06/02/2017 - 19:00
Matt and Mike interview Drupal Association Executive Director Megan Sanicki, and Drupal community discussion facilitator Whitney Hess about the history, present, and future of Drupal governance.

DrupalCon News: DrupalCon Vienna t-shirts are back! - but there’s a catch.

Fri, 06/02/2017 - 18:15
div class=field field--name-body field--type-text-with-summary field--label-hiddendiv class=field__itemsdiv class=field__item evenpRemember how we are a style=color:#4C697D;text-decoration:underline;font-weight:600; href=https://www.drupal.org/association/blog/drupalcon-vienna-program-changesmaking changes to DrupalCon Europe/a? These were hard decisions and some things we love we found just weren’t financially viable. Like free t-shirts. But one thing we heard a lot was “please don’t take away the t-shirts!” nbsp;/p pWe heard you. And while it doesn'tnbsp;make financial sense to give free t-shirts to all attendees, we still want to be able to continue to offer them. So we’ve come up with a plan./p /div/div/div

Drupal Association blog: DrupalCon Vienna t-shirts are back! - but there’s a catch.

Fri, 06/02/2017 - 16:42
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item evenpimg alt=DrupalCon Vienna T-shirts height=339 src=/files/NewsClipTees_0.png width=1359 //p pRemember how we are a href=https://www.drupal.org/association/blog/drupalcon-vienna-program-changes rel=nofollowmaking changes to DrupalCon Europe/a? These were hard decisions and some things we love we found just weren’t financially viable. Like free t-shirts. But one thing we heard a lot was “please don’t take away the t-shirts!”  /p pWe heard you. And while it doesn’t make financial sense to give free t-shirts to all attendees, we still want to be able to continue to offer them. So we’ve come up with a plan.   /p pAt DrupalCon Vienna, t-shirts will be offered to the following groups:/p ulli pIndividual Drupal Association members who register for DrupalCon Vienna between 5 - 16 June 2017. You must register in this two week window AND be an individual member of the Drupal Association./p /li li pVolunteers who work at least four (4) hours onsite in Vienna 26 - 29 September. You must check the volunteer box during registration and must show up on site to volunteer for four (4) hours or until released by event staff./p /li li pVolunteers as part of the DrupalCon Program Team/p /li li pSprint Mentors/p /li /ulh3The fine print FAQ/h3 pstrongI’m already a member, how do I make sure that I'll get a shirt?/strong/p pIf you are already an individual member, you get a t-shirt! BUT you MUST register in the first two weeks of ticket sales. Registrations after 16 June will not receive a t-shirt, member or not./p pstrongI’m not a member, can I do that during registration and still get a shirt?/strong/p pYes. If you are not a member you can become an individual member during your conference registration. You will be presented with a page during check-out that gives you the option to become a member./p pstrongI already registered but JUST saw this post! What do I do?/strong/p pIf you are a true early bird and register in the two weeks, but somehow missed this news post until after registering - that’s ok. As long as you become a member before the end of 16 June and you’ll still get a t-shirt./p pstrongThe registration didn’t say anything about t-shirts or ask for my t-shirt size? What’s up?/strong/p pAfter the 16 June cut-off date, eligible registrants will receive an email confirming their t-shirt along with a link to select their t-shirt size./p pstrongYou got a session selected? Great! /strong/p pWe’ll refund your registration amount (but not your membership) and you get to keep the t-shirt. Our regular no-refund policy applies to all other sales./p pstrongYou’re part of an organization that is buying a bulk amount of tickets for employees? Lucky you. /strong/p pYour organization should provide you with an individual redemption code. You’ll need to redeem your individual registration before 16 June AND also be an individual member of the Drupal Association in order to get a t-shirt./p/div/div/div

Sudhanshu Gautam | Blog: GSoC 17 | Community bonding wrap-up

Fri, 06/02/2017 - 06:30
span property=schema:name class=field field--name-title field--type-string field--label-hiddenGSoC 17 | Community bonding wrap-up/span span rel=schema:author class=field field--name-uid field--type-entity-reference field--label-hiddenspan lang= about=http://sudhanshug.com/blog/user/1 typeof=schema:Person property=schema:name datatype= xml:lang=sudhanshu/span/span span property=schema:dateCreated content=2017-06-02T04:30:56+00:00 class=field field--name-created field--type-created field--label-hiddenFri, 06/02/2017 - 10:00/span

groups.drupal.org frontpage posts: Ready, Set, Code - GSoC 2017 starts now!

Thu, 06/01/2017 - 20:44
pDid you know Drupal was accepted into Google Summer of Code 2017 and that Drupal selected 8 projects? In other words, Google is funding 8 people to contribute to Drupal for 10 weeks worth ~$40,000 USD (thank you Google!). Congratulations to selected students who collectively became one of the top 20 contributing organizations on drupal.org (list @ a href=https://www.drupal.org/organizations title=https://www.drupal.org/organizationshttps://www.drupal.org/organizations/a). Proud to note that all GSoC 2017 students have already become core contributors!/p pMajority of projects are focused on work related to Drupal 8 contributed modules. Drupal's students are all from Indian except one student from the UK, we currently have 15 mentors from 10 countries with over 100 years of experience on drupal.org. As always, we're excited about this summer and we hope community members will provide an extra helping hand if you see students in issue queues. GSoC runs from May 30th through August 21st 2017. Learn more about a href=https://summerofcode.withgoogle.com/organizations/5186660074520576/#5408497358340096our projects/a below./p pProject: a href=https://summerofcode.withgoogle.com/projects/#5408497358340096A Module for client-side File encryption to implement a zero-knowledge systembr //aStudent: Tameesh Biswas “a href=https://www.drupal.org/u/tameeshbtameeshb/a” (India)br /Mentors: Colan Schwartz “a href=https://www.drupal.org/u/colancolan/a” (Canada), Adam Bergstein “a href=https://www.drupal.org/u/nerdsteinnerdstein/a” (USA), Talha Paracha “a href=https://www.drupal.org/u/talhaparachatalhaparacha/a” (Pakistan)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#5507901155180544Adding support for Theleague oauth and new implementers for social auth and social postbr //aStudent: Himanshu Dixit “a href=https://www.drupal.org/u/himanshu-dixithimanshu-dixit/a” (India)br /Mentors: Getulio Sánchez “a href=https://www.drupal.org/u/gvsogvso/a” (Paraguay), Daniel Harris “a href=https://www.drupal.org/u/dahacoukdahacouk/a” (UK)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#6508645715017728Client-side public-key encryption module for Drupal 8br //aStudent: Marcin Czarnecki “a href=https://www.drupal.org/u/marnczmarncz/a” (UK)br /Mentors: Colan Schwartz “a href=https://www.drupal.org/u/colancolan/a” (Canada), Adam Bergstein “a href=https://www.drupal.org/u/nerdsteinnerdstein/a” (USA), Talha Paracha “a href=https://drupal.org/u/talhaparachatalhaparacha/a” (Pakistan)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#6124763222114304Complete porting of Examples for Developers Sub-modules to D8br //aStudent: Abhishek Lal “a href=https://www.drupal.org/u/abhisheklalAbhishekLal/a” (India)br /Mentors:  Navneet Singh “a href=https://www.drupal.org/u/navneet0693navneet0693/a” (India), Vaibhav Jain “a href=https://www.drupal.org/u/vaibhavjainvaibhavjain/a” (India)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#6180950386933760Creating a great geospatial experience in Drupal 8 by porting and enhancing the Search_Api_Location modulebr //aStudent: Dibyajyoti Panda “a href=https://www.drupal.org/u/dbjpandadbjpanda/a” (India)br /Mentors: Nick Veenhof “a href=https://www.drupal.org/u/nick_vhNick_vh/a” (Belgium), Thomas Seidl “a href=https://www.drupal.org/u/drunken-monkeydrunken monkey/a” (Austria), Joris Vercamen “a href=https://www.drupal.org/u/borisson_borisson_/a” (Belgium)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#5950145286897664Port Vote up/down module to Drupal 8br //aStudent: Sudhanshu Gautam “a href=https://www.drupal.org/u/sudhanshugsudhanshug/a” (India)br /Mentors: Marco Villegas “a href=https://www.drupal.org/u/marvil07marvil07/a” (Peru), Palash Vijay “a href=https://www.drupal.org/u/palashvijay4opalashvijay4O/a” (India)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#5404655919038464Integrate Google Cloud Machine Learning Engine to Drupal 8br //aStudent: boby aloysius johnson “a href=https://www.drupal.org/u/boaloysiusboaloysius/a” (India)br /Mentors: Jingsheng Wang “a href=https://www.drupal.org/u/skyredwangskyredwang/a” (China), Naveen Valecha “a href=https://www.drupal.org/u/naveenvalechanaveenvalecha/a” (India)/p pProject: a href=https://summerofcode.withgoogle.com/projects/#4561661213016064Port Uc wishlist module to Drupal 8br //aStudent: Chiranjeeb Mahanta “a href=https://www.drupal.org/u/chiranjeeb2410chiranjeeb2410/a” (India)br /Mentors: Naveen Valecha “a href=https://www.drupal.org/u/naveenvalechanaveenvalecha/a” (India)/p pFind us on IRC in #drupal-google to join the fun. Interested in mentoring or have questions about this initiative? Contact Drupal's Organization Admin a href=https://drupal.org/u/slurpee target=_blankSlurpee/a (USA) with any questions./p

Mediacurrent: Comparing Drupal and Adobe Experience Manager (Part 2 of 2)

Thu, 06/01/2017 - 16:39
img typeof=foaf:Image src=https://www.mediacurrent.com/sites/default/files/styles/thumb_blog_spotlight/public/comparing-drupal-adobe-v3-01.png?itok=EHkVFxI9 width=200 height=152 alt=Comparing Drupal and Adobe Experience Manager title=Comparing Drupal and Adobe Experience Manager / pThis is Part 2 of 2 of my Drupal vs Adobe Experience Manager (AEM) blog post. In the a href=https://www.mediacurrent.com/blog/comparing-drupal-and-adobe-experience-manager-part-1-2first part/a, I've compared the two from the perspectives of content authoring, marketing, and business. In this part, I look at the two from an IT and community perspective. I also need to repeat my disclaimer that I'm a long-time Drupalist, but in this blog post I endeavor to be even-minded and objective.br / /p

Acquia Developer Center Blog: From imagination to (augmented) reality in 48 hours

Thu, 06/01/2017 - 16:21
div class=field field-name-field-blog-image field-type-image field-label-hiddendiv class=field-itemsdiv class=field-item evenimg typeof=foaf:Image class=img-responsive src=https://dev.acquia.com/sites/default/files/styles/blog__190_x110_/public/screen_shot_2017-05-30_at_4.03.50_pm.png?itok=mYK1lTtc width=140 height=85 alt=acquia engineering team title=acquia engineering team //div/div/divdiv class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpEvery spring, members of Acquia's Product, Engineering and DevOps teams gather at our Boston headquarters for Build Week. Build Week gives our global team the opportunity to meet face-to-face, to discuss our product strategy and roadmap, to make plans, and to collaborate on projects./p/div/div/divdiv class=field field-name-field-blog-tags field-type-taxonomy-term-reference field-label-inline clearfixdiv class=field-labelTags:nbsp;/divdiv class=field-itemsdiv class=field-item evena href=/tags/acquia-drupal-planet typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=acquia drupal planet/a/div/div/div

Acquia Developer Center Blog: Announcing OpenEDU: An open source Drupal distribution for higher education

Thu, 06/01/2017 - 15:05
div class=field field-name-field-blog-image field-type-image field-label-hiddendiv class=field-itemsdiv class=field-item evenimg typeof=foaf:Image class=img-responsive src=https://dev.acquia.com/sites/default/files/styles/blog__190_x110_/public/blog/openedu_1_620b.png?itok=16pbc6Qv width=140 height=85 alt=openedu logo title=openedu logo //div/div/divdiv class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpWhen organizations are able to save time and money during development, they are able to devote more resources to strategic and innovative initiatives. The ability to jumpstart development and extend invaluable resources is especially important to institutions of higher education. /p pa href=http://imagexmedia.com/openedu target=_blankOpenEDU/a is a pre-configured Drupal 8 implementation that is specifically built for higher education institutions. It enables universities to accelerate the development of sites by providing a “kickstart” set of features. /p /div/div/divdiv class=field field-name-field-blog-tags field-type-taxonomy-term-reference field-label-inline clearfixdiv class=field-labelTags:nbsp;/divdiv class=field-itemsdiv class=field-item evena href=/tags/acquia-drupal-planet typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=acquia drupal planet/a/div/div/div

Chapter Three: A Better Website Editing Experience with Modular Content Components

Thu, 06/01/2017 - 12:26
pThe editorial experience is a critical and often overlooked part of website development. A weak editorial experience means slower site updates. Without a robust and intuitive content creation process, editors lose motivation to keep their site up to date. Our modular content creation process makes it quick and easy for editors to create content while providing front-end users with a rich visual experience./p h2What Are Modular Content Components?/h2 pModular Content Components are a powerful way for website editors to quickly add new sections and send article content to multiple distribution channels in a single step. Drupal sites with Modular Content Components make it easy to add new distribution channels and send custom formats to each./p

Agiledrop.com Blog: AGILEDROP: Drupal Blogs from May

Thu, 06/01/2017 - 11:07
a href=http://www.agiledrop.com/blog/drupal-blogs-mayimg src=https://www.agiledrop.com/sites/default/files/2017-06/tulips-2544_640.jpg //a As the time goes by, our blog activities don't rest. We have written quite a lot of blog posts about Drupal for you in the past month. Therefore, it' time to look at the topics we covered in May. We decided that we will focus on the biggest Drupal Conference, which took place in Baltimore. Therefore, we began our month with Case studies from DrupalCon Baltimore. We looked at who had sessions in that area and what they have presented to the audience. Since we promised that we will be more informative about where we will be and on which Drupal event we will go, we continued the month with… a href=http://www.agiledrop.com/blog/drupal-blogs-mayREAD MORE/a

Dries Buytaert: From imagination to (augmented) reality in 48 hours

Thu, 06/01/2017 - 09:31
pEvery spring, members of Acquia's Product, Engineering and DevOps teams gather at our Boston headquarters for Build Week. Build Week gives our global team the opportunity to meet face-to-face, to discuss our product strategy and roadmap, to make plans, and to collaborate on projects. /p pOne of the highlights of Build Week is our annual Hackathon; more than 20 teams of 4-8 people are given 48 hours to develop any project of their choosing. There are no restrictions on the technology or solutions that a team can utilize. Projects ranged from an a href=https://www.amazon.com/Dash-ButtonsAmazon Dash Button/a that spins up a new Acquia Cloud environment with one click, to a Drupal module that allows users to visually build page layouts, or a proposed security solution that would automate a href=https://en.wikipedia.org/wiki/Penetration_testpen testing/a against Drupal sites. /p pThis year's projects were judged on innovation, ship-ability, technical accomplishment and flair. The winning project, Lift HoloDeck, was particularly exciting because it showcases an a href=http://buytaert.net/drupal-is-for-ambitious-digital-experiencesambitious digital experience/a that is possible with Acquia and Drupal today. The Lift Holodeck takes a physical experience and amplifies it with a digital one using a href=https://en.wikipedia.org/wiki/Augmented_realityaugmented reality/a. The team built a mobile application that superimposes product information and smart notifications over real-life objects that are detected on a user's smartphone screen. It enables customers to interact with brands in new ways that a href=http://buytaert.net/friduction-the-internets-unstoppable-drive-to-eliminate-frictionimprove a customer's experience/a./p pfigure class=figurediv class=img style=border: 1px solid #ccc; display: inline-block img src=http://buytaert.net/files/cache/acquia/lift-holodeck-banner-742x1114.jpg style=display:block alt= //div /figure/p pAt the hackathon, the Lift HoloDeck Team showed how augmented reality can change how both online and physical storefronts interact with their consumers. In their presentation, they followed a customer, Neil, as he used the mobile application to inform his purchases in a coffee shop and clothing store. When Neil entered his favorite coffee shop, he held up his phone to the posted “deal of the day”. The Lift HoloDeck application superimposes nutrition facts, directions on how to order, and product information on top of the beverage. Neil contemplated the nutrition facts before ordering his preferred drink through the Lift HoloDeck application. Shortly after, he received a notification that his order was ready for pick up. Because Acquia Lift is able to track Neil's click and purchase behavior, it is also possible for Acquia Lift to push personalized product information and offerings through the Lift HoloDeck application./p pCheck out a href=https://www.youtube.com/embed/3XJK_sn8bngthe demo video/a, which showcases the Lift HoloDeck prototype:/p iframe width=640 height=360 src=https://www.youtube.com/embed/3XJK_sn8bng frameborder=0 allowfullscreen=/iframep/p pThe Lift HoloDeck prototype is exciting because it was built in less than 48 hours and uses technology that is commercially available today. The Lift HoloDeck experience was powered by a href=https://unity3d.com/Unity/a (a 3D game engine), a href=https://www.vuforia.com/Vuforia/a (an augmented reality library), a href=https://www.acquia.com/products-services/acquia-liftAcquia Lift/a (a personalization engine) and a href=http://drupal.orgDrupal/a as a content store. /p pThe Lift HoloDeck prototype is a great example of how an organization can use Acquia and Drupal to support a href=http://buytaert.net/cross-channel-user-experiences-with-drupalnew user experiences and distribution platforms/a that engage customers in captivating ways. It's incredible to see our talented teams at Acquia develop such an innovative project in under 48 hours; especially one that could help reshape how customers interact with their favorite brands. /p pemCongratulations to the entire Lift HoloDeck team; Ted Ottey, Robert Burden, Chris Nagy, Emily Feng, Neil O'Donnell, Stephen Smith, Roderik Muit, Rob Marchetti and Yuan Xie./em/p

Hook 42: Roping in TextWrangler

Thu, 06/01/2017 - 00:53
div class=image div class=field-items class=field-items div class=field-item even rel=og:image rdfs:seeAlso resource=http://www.hook42.com/sites/default/files/styles/image_style_blog_list/public/field/image/screen_shot_2017-05-31_at_7.18.05_am.png?itok=yHpHuAMZ class=field-item evenimg typeof=foaf:Image src=http://www.hook42.com/sites/default/files/styles/image_style_blog_list/public/field/image/screen_shot_2017-05-31_at_7.18.05_am.png?itok=yHpHuAMZ width=230 height=220 alt=TextWranglin#039; Cowgirl title=TextWranglin#039; Cowgirl //div /div /div div class=field field-name-body field-type-text-with-summary field-label-hidden field-wrapper body field div class=field-items class=field-items div class=field-item even property=content:encoded class=field-item evenpAs Hook 42's Community Evangelist, I frequently venture into the prairie of a href=https://www.drupal.org/docs/develop/documenting-your-projectDrupal documentation/a. It's not quite the Wild Wild West, but having a solid text editor in my holster keeps me saddled up and ready to ride.br br Since I don't venture too far off the ranch into programming, I don't really have the need for a heavy IDE (Integrated Development Environment). I just need a tool that works on my Mac,nbsp;writes with no fancy characters, and has the ability to do some basic formatting. TextWrangler definitely keeps me from squatting on my spurs, and the best part - it's free!/p /div /div /div

Lullabot: Running Behat Tests in a Vagrant Box

Wed, 05/31/2017 - 18:01
div class=rich-textdiv class=rich-text__contentpFor a while now, a href=https://www.vagrantup.com/Vagrant/a has been my local development environment of choice. It#x2019;s great for a lot of reasons but sometimes working in what is essentially a remote environment, has its challenges. One such challenge is running a href=http://behat.org/en/latest/Behat/a Tests in a native browser like Chrome with a href=http://www.seleniumhq.org/Selenium/a./p pa href=http://behat.org/en/latest/Behat/a tests are the beeapos;s knees. They are especially so when you can see your tests executed automatically in your desktop browser for easy debugging:/p /divdiv class=rich-text__embeddiv class=videoiframe allowfullscreen frameborder=0 src=https://www.youtube.com/embed/1eDvPXkrR6wVideos require iframe browser support./iframe/div/divdiv class=rich-text__content pHowever, if you use a href=https://www.vagrantup.com/Vagrant/a for local development you often lose the benefit of visualizing your test run because many off-the-shelf boxes you find on the internet are configured to run a href=http://behat.org/en/latest/Behat/a tests using headless browsers like a href=http://phantomjs.org/PhantomJS/a or a href=https://medium.com/@griggheo/running-selenium-webdriver-tests-using-firefox-headless-mode-on-ubuntu-d32500bb6af2headless Firefox with xvfb/a. Itapos;s certainly easier to get set up running your tests using a href=http://phantomjs.org/PhantomJS/a, but it doesn#x2019;t have to be this way:/p /divdiv class=rich-text__embeddiv class=videoiframe allowfullscreen frameborder=0 src=https://www.youtube.com/embed/glplozmmv30Videos require iframe browser support./iframe/div/divdiv class=rich-text__content pYou can configure your a href=http://behat.org/en/latest/Behat/a tests to run in your desktop browser so you can see everything. You can even get fancy and set breakpoints in your tests using an IDE like a href=https://www.jetbrains.com/phpstorm/PHPStorm/a, halting the browser execution and giving you the opportunity to pop open Chrome dev tools or the like to really understand what#x2019;s going on during your test./p pThis article assumes a few things:/p ulliLocal development environment using a href=https://www.vagrantup.com/Vagrant/a for your Drupal site/li liFamiliarity with a href=http://behat.org/en/latest/Behat/a and a href=http://www.seleniumhq.org/Selenium/a/li lia href=https://sites.google.com/a/chromium.org/chromedriver/Chrome/a for running the tests/li /ul pIf you#x2019;re unfamiliar with a href=http://behat.org/en/latest/Behat/a, a href=http://www.seleniumhq.org/Selenium/a and/or a href=https://www.vagrantup.com/Vagrant/a, they are awesome, and you should check them out. Also, while we#x2019;re going to use Chrome here, you could use any browser supported by Selenium and your host operating system. Onwards./p h2Setup/h2 pThere are a few things to get set up. Following is a diagram to help you understand the interaction between all the pieces as a way to visualize what you need:/p /divdiv class=rich-text__embedundefined/divdiv class=rich-text__content pThe above diagram shows the test suite run by Behat (1) on the Vagrant box. Behat talks to the Selenium hub (2) server running on the Vagrant box, which talks to the Selenium node (3) server on the host machine. Finally, the Selenium node server is what drives Chrome (4) to execute the test suite. Not to worry if you don#x2019;t understand what these things do, we#x2019;ll get into that below./p pTo get started with the setup, first ensure that you have the Java Runtime Environment (JRE) installed on your host machine and in the Vagrant box, which is required to run Selenium. You may already have it installed, but can check with:/p div class=codepre code$ java -version/code/pre/div pI#x2019;m running JRE 1.8. If you need to install or update, Google is your friend./p pNext, you#x2019;ll need Selenium. It#x2019;s handy to download it into a shared folder between the host machine and the Vagrant box. The important thing is that it#x2019;s available on both the host machine and Vagrant box./p div class=codepre code$ wget http://selenium-release.storage.googleapis.com/2.53/selenium-server-standalone-2.53.1.jar/code/pre/div pFinally, you#x2019;ll need Chrome driver on the host machine. For convenience move it somewhere on your PATH:/p div class=codepre code$ wget https://chromedriver.storage.googleapis.com/span class=code__number2.29/span/chromedriver_mac64.zip $ unzip chromedriver_mac64.zip $ mv chromedriver /usr/span class=code__built_inlocal/span/bin/code/pre/div h2Run tests/h2 pNow that you have all the software you need, it#x2019;s time to run the tests. First thing you#x2019;ll want to do is start Selenium server in hub mode in the Vagrant box:/p div class=codepre code$ java -jar /path/to/selenium/selenium-server-standalone-2.53.1.jar -role hub/code/pre/div pNotice the code-role hub/code option. This tells Selenium to run in hub mode. Running Selenium in hub mode allows Selenium to receive tests to be executed and forward them to any registered Selenium servers running in node mode. The Selenium server running in node mode is what controls the browser, driving the browser through the tests. In this way you can bridge the gap between the Vagrant box and the host machine, so that you can see the tests running in a browser on the host machine. You#x2019;ve already got the Selenium server in hub mode running on the Vagrant box. Now lets start a Selenium server in node mode on the host machine:/p div class=codepre code$ java -jar /path/to/selenium/selenium-server-standalone-2.53.1.jar -role node -hub http://my-vbox.local:4444/grid/register -Wdriver.chrome.driver=/path/to/chromedriver/code/pre/div pHere, you#x2019;re telling Selenium to run in node mode, using the code-role node/code option. You#x2019;re also registering the Selenium node with the Selenium hub running in your Vagrant box using the code-hub http://my-vbox.local:4444/grid/register/code option. Replace codemy-vbox.local/code with the host name or IP address of your Vagrant box./p pNext you#x2019;ll need to adjust your codebehat.yml/code file to register a Selenium Mink session, that points to the Selenium hub server running in the Vagrant box e.g.,/p div class=codepre codeselenium2: wd_host: quot;http://my-vbox.local:4444/wd/hubquot;/code/pre/div pSo that your codebehat.yml/code file looks something like this:/p div class=codepre codedefault: suites: default: contexts: - FeatureContext - Drupal\DrupalExtension\Context\DrupalContext - Drupal\DrupalExtension\Context\MinkContext extensions: Behat\MinkExtension: goutte: ~ selenium2: wd_host: quot;http://my-vbox.local:4444/wd/hubquot; base_url: http://my-vbox.local browser_name: apos;chromeapos; Drupal\DrupalExtension: blackbox: ~ api_driver: apos;drupalapos; drush: alias: apos;localapos; drupal: drupal_root: apos;/var/www/docrootapos;/code/pre/div pWith all that setup, you#x2019;re finally ready to run your tests. From your Vagrant box, run:/p div class=codepre code$ ./vendor/bin/behat -v -c /path/to/behat.yml /path/to/behat/features/code/pre/div pIf everything worked out, you#x2019;ll see Selenium open up a new instance of Chrome and drive it through the test suites:/p /divdiv class=rich-text__embeddiv class=videoiframe allowfullscreen frameborder=0 src=https://www.youtube.com/embed/TRAJiJqkx4AVideos require iframe browser support./iframe/div/divdiv class=rich-text__content h2Further Reading/h2 pa href=http://behat.org/en/latest/Behat/abr/a href=https://github.com/Behat/MinkExtension/blob/master/doc/index.rstBehat Mink Extension/abr/a href=http://mink.behat.org/en/latest/drivers/selenium2.htmlMink Selenium 2 Driver/abr/a href=http://www.seleniumhq.org/Selenium/abr/a href=http://kevinquillen.com/bdd/2014/06/06/behat-drupalUp and Running with Behat, Drupal, amp; Vagrant/abr/a href=https://www.phparch.com/2016/08/testing-your-drupal-site-with-behat/Testing Your Drupal Site with Behat/abr/a href=https://github.com/simongrimes/vagrant-behatsimongrimes/vagrant-behat/a/p /div/div

OSTraining: How to Use Tokens in Drupal Fields

Wed, 05/31/2017 - 17:11
pimg src=https://www.ostraining.com/images/drupal/drupal-tokens.jpg alt=How to Use Tokens in Drupal Fields style=float: right; /Token is one of the 3 most popular modules in Drupal./p pIt allows you to use small placeholders to automatically complete tasks./p pTo take a simple example, if you put [site:name] on your site, it will be replaced by the actual name of your site. To take a more complicated example, you can use Token together with the Pathauto module to automatically create URL patterns for your whole site./p