Planet Drupal

Syndicate content - aggregated feeds in category Planet Drupal
Updated: 29 min 39 sec ago

Mediacurrent: Dropcast Episode 27: So Long 2016

Thu, 12/22/2016 - 20:47
img typeof=foaf:Image src= width=200 height=152 / p dir=ltrRecorded December 14th, 2016./p p dir=ltrIn this, our final episode of 2016, we some time to reflect on the great things of the year, and take a look into 2017. We also expanded the Pro Project Pick into the Pro Project Pick of the Year. And as always we look at the latest Drupal news,  events and Ryan rides his sleigh in The Final Bell. Have a happy holiday, and we'll see you next year!/p

Blair Wadman: Introduction to Annotations in Drupal 8

Thu, 12/22/2016 - 18:52
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpAnnotations are another one of the new concepts in Drupal 8 to wrap your head around. Annotations are written as PHP code comments above a class or function and contain metadata about the function or class./p pAnnotations are used by other PHP projects. For example, Symfony2 uses annotations for routing rules and Doctrine uses them for ORM related meta data./p/div/div/div

Evolving Web: Things to know before moving from Drupal 6 or 7 to Drupal 8

Thu, 12/22/2016 - 18:00
a href= img src= width=220 height=165 alt=Things to know before moving from Drupal 6 or 7 to Drupal 8 typeof=Image class=img-responsive //apSince the release of Drupal 8, a href= 6 is no longer supported by the Drupal Community/a. Because of this, many sites need to be migrated to Drupal 7 or 8, and quickly!/p pThat means that at Evolving Web we've been doing a lot of Drupal 8 migration projects lately, either emD6 to D8/em or emD7 to D8./em I would like to talk about the things we have to take into account when running these projects./pa href= hreflang=enread more/a

Third Grove: Creating a CKEditor plugin with Drupal 7 using WYSIWYG

Thu, 12/22/2016 - 17:32
span property=schema:name class=field-name--titleCreating a CKEditor plugin with Drupal 7 using WYSIWYG/span span class=field-name--uid rel=schema:authorspan lang= about= typeof=schema:Person property=schema:name datatype= xml:lang=josh@thirdandg…/span/span span property=schema:dateCreated content=2016-12-22T16:32:29+00:00 class=field-name--createdThu, 12/22/2016 - 11:32/span

Acquia Developer Center Blog: How to Submit a Session Proposal to DrupalCon That Will be Accepted: Nine Steps to Success

Thu, 12/22/2016 - 15:42
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= width=140 height=85 alt=drupalcon baltimore logo title=drupalcon baltimore 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:encodedpa href= Baltimore/a is coming up April 24 through April 28, 2017. /p pWhy not make this the year that you present a session? /p pIf the idea of submitting a session sounds appealing, focus for a few seconds on this date: strongFebruary 1, 2017/strong at 23:59 EST (UTC -5). That’s the deadline for submitting a session proposal./p pOkay, now let’s work backwards from that. /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

DrupalOnWindows: Drupal 7 update jQuery.once: jquery.once polyfill

Thu, 12/22/2016 - 12:24
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpIn this post I will share a quick tip on how to upgrade the jquery.once plugin in Drupal 7 without breaking current code./p pDrupal 7 ships with jquery.once plugin version 1.2 that dates from 2013. For a project we needed to make code targeting the old 1.x and the 2.x work at the same time. In our case this was core javascript written for 1.x working with some code of ours designed for jquery.once 2.x./p pThe solution is easy: upgrade the core jquery.once to 2.x and add a polyfill to make it backwards compatible./p/div/div/divdiv class=form-item form-type-item labelLanguage /label English /div div class=view view-read-more view-id-read_more view-display-id-entity_view_1 view-dom-id-140052cd6a350f5e829500341b063f37 div class=view-header hr/ h2More articles.../h2 /div div class=view-content div class=item-list ul li class=views-row views-row-1 views-row-odd views-row-first div class=views-field views-field-title span class=field-contenta href=/en/blog/profiling-drupal-xhprof-uprofiler-tideways-php7-linux-and-windowsProfiling Drupal: XHprof, Uprofiler, Tideways with PHP7 on Linux and Windows/a/span /div/li li class=views-row views-row-2 views-row-even div class=views-field views-field-title span class=field-contenta href=/en/blog/fixing-slow-queries-and-database-deadlocks-drupal-without-php-profiling-toolsFixing slow queries and database deadlocks in Drupal without PHP profiling tools/a/span /div/li li class=views-row views-row-3 views-row-odd div class=views-field views-field-title span class=field-contenta href=/en/blog/running-drupal-8-php-7Running Drupal 8 on PHP 7/a/span /div/li li class=views-row views-row-4 views-row-even div class=views-field views-field-title span class=field-contenta href=/en/blog/using-linq-language-integrated-queries-drupal-or-how-write-queries-x5-fasterUsing LINQ (Language Integrated Queries) in Drupal or how to write queries x5 faster/a/span /div/li li class=views-row views-row-5 views-row-odd div class=views-field views-field-title span class=field-contenta href=/en/blog/drupal-7-update-jqueryonce-jqueryonce-polyfillDrupal 7 update jQuery.once: jquery.once polyfill/a/span /div/li li class=views-row views-row-6 views-row-even div class=views-field views-field-title span class=field-contenta href=/en/blog/benchmarking-drupal-7-php-7-devBenchmarking Drupal 7 on PHP 7-dev/a/span /div/li li class=views-row views-row-7 views-row-odd div class=views-field views-field-title span class=field-contenta href=/en/blog/build-git-windows-sourcesBuild GIT on Windows from Sources/a/span /div/li li class=views-row views-row-8 views-row-even div class=views-field views-field-title span class=field-contenta href=/en/blog/hiding-fact-your-site-runs-drupalHiding the fact that your site runs Drupal/a/span /div/li li class=views-row views-row-9 views-row-odd div class=views-field views-field-title span class=field-contenta href=/en/blog/drupal-iis-or-apacheDrupal on IIS or Apache/a/span /div/li li class=views-row views-row-10 views-row-even views-row-last div class=views-field views-field-title span class=field-contenta href=/en/blog/installing-drupal-8-windowsInstalling Drupal 8 on Windows and SQL Server/a/span /div/li /ul/div /div /div

Unimity Solutions Drupal Blog: Building Chat Bots on Drupal

Thu, 12/22/2016 - 12:01
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpBuilding chat bots depends on number of factors like experience with programming language, understanding A.I, writing stellar bot conversations, understanding your company's requirement, purpose of deploying chat bot - Customer Service, Customer Engagement or Product design etc./p /div/div/div

DrupalCon News: Let’s hear your ideas, thoughts, feedback on core

Wed, 12/21/2016 - 21:53
div class=field field--name-body field--type-text-with-summary field--label-hiddendiv class=field__itemsdiv class=field__item evenpDrupalCon offers a a href= Conversation track/a where people present on various topics ranging from what’s currently in core, how can we improve something, what should go in future releases, and sometimes what is not going so well in the core world./p/div/div/div

Chromatic: Drupal Code Standards: Twig in Drupal 8

Wed, 12/21/2016 - 19:24
pThis is the seventh post in a series about coding standards. In this post we’ll talk about how to adhere to standards while implementing Twig templating in Drupal 8./p

Chromatic: Drush SQL Sync Alternative: SQL Sync Pipe

Wed, 12/21/2016 - 19:24
pUsing Drush to sync databses (codedrush sql-sync/code) is a valuable tool, but it is not always an efficient choice when dealing with large databases (think over 1GB)./p

Chromatic: Create a Custom Views Sort Plugin with Drupal 8

Wed, 12/21/2016 - 19:24
pTap into the power of Views with a custom sort plugin in Drupal 8. Code samples included./p

Chromatic: The Road to Speaking at DrupalCon

Wed, 12/21/2016 - 19:24
pEarlier this year I was fortunate to speak at DrupalCon New Orleans. I'd been working towards speaking at DrupalCon for a few years and it wasn’t until after I spoke that I reflected on just how much effort went into it. I had underestimated the process. Because I’m likely not alone in doing so, I’d like to share what I have learned along the way./p blog:'s Composer endpoints are out of beta

Wed, 12/21/2016 - 18:03
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item evenpimg Composer Logo class=left src=/files/styles/grid-3/public/project-images/9769826_0.png width=120px //p's Composer endpoints have been available in beta for some time now, and in that time we've begun to see many, many people use Composer to manage Drupal modules and themes. We first launched these repositories before DrupalCon New Orleans as an alpha release, and move into beta a few months later. After receiving your feedback and bug reports we've made updates, and are ready to call this service stable./p h2What is Composer?/h2 blockquotepComposer is a tool for dependency management in PHP. It allows you to declare the libraries your project depends on and it will manage (install/update) them for you./p p… Composer is strongly inspired by node's npm and ruby's bundler. - a href= rel=nofollowSource/a/p /blockquote pIn a nutshell, Composer allows you to declare the dependencies of your project in a composer.json file in the root of your PHP project. Those dependencies, which you then install through Composer, can have their emown/em composer.json files and their own dependencies—all of which will be automatically managed and installed by Composer. When you need specific control over the versions of dependencies, you can use a a href= rel=nofollowcomposer.lock/a file./p pYou can read more about Composer at a href= h2How do's composer repositories work?/h2 offers two Composer repositories—one for Drupal 7, and one for Drupal 8. Composer requires that packages adhere to semantic versioning, which Drupal 8 core does, but Drupal 8 contrib, and Drupal 7 core and contrib, don’t. To solve this problem, we've created a Composer façade, which takes all of the metadata about projects on and translates them into a format Composer can understand—including translating the Drupal-specific versioning for Drupal 7 and contrib into semantic versioning./p pBy creating this façade, we've made sure that is still the canonical source for metadata about projects, and that we can update this translation layer as the versioning schema changes. (Learn more about the effort to a href= rel=nofollowmove Contrib projects to semantic versioning/a)./p pIn addition to providing endpoints for building projects, Drupal's automated testing suite— a href= rel=nofollowDrupalCI/a—now uses Composer to test Drupal core and contributed projects. This allows developers to test any external dependencies./p h2How do I use's Composer repositories?/h2 pTo begin using's Composer repositories, you'll need to update your composer.json file to include the appropriate Composer repository for the version of Drupal. To use Composer with Drupal 7, use the repository url:/p pre To use Composer with Drupal 8, use the repository url:/p pre, as in this example./p pAfter setting up composer, simply run the command:/p pre code class=language-php$ composer config repositories.drupal composer /code/prepAnd your project's composer.json should be updated to look like the following:/p pre code class=language-php{ repositories: { drupal: { type: composer, url: } } } /code/prepOnce you've made that change, you should be able to use Composer for Drupal modules and themes as you would for any other PHP package, using the drupal/ namespace:/p pre code class=language-php$ composer require drupal/lt;modulenamegt; /code/prepThere is one caveat about the pattern: there are some namespace collisions among modules, and so it is on our roadmap to update project pages to specify the exact namespace to use to require a given project./p pTo learn more about how to use's Composer repositories, and for some troubleshooting tips, read the a href= rel=nofollowProject Composer documentation/a./p h2What about licensing?/h2 pAll the projects hosted on are licensed GPLv2 or later or have an a href= rel=nofollowentry in the packaging whitelist/a. This means that you can rely on Drupal Core and contributed modules and themes to be licensed under the GPL or compatible. And if you need to redistribute your code created with Drupal projects, it must be redistributed as GPLv2 or later./p pHowever, because Composer is a tool that can manage packages in the wider PHP ecosystem, you might find that you want to require a non-GPL package in your project. Using GPL-licensed Drupal projects with external packages that are GPL compatible is fine. Just be aware that if you redistribute that code, you will have to redistribute under a GPL license./p pWe cannot provide legal advice for your use of open source software. If you use Composer to install packages that are not compatible with the GPL alongside GPL-licensed projects like Drupal, you may use that software together, but per the terms of the GPL you may not copy, distribute, or modify that software./p pActivities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted… a href= rel=nofollowGPL 2.0 Section 0/a./p pFor more questions about Drupal and the GPL you can read the a href= rel=nofollowLicensing FAQ/a./p h2What's next?/h2 pAt this point, the Composer service is stable and you can use it to manage modules and themes in your production websites. That said, we do have a roadmap of additional features that we'd like to add. And your contributions are welcome!/p pAs development on's Composer service continues, we want to focus on the following features:br / Supporting Composer-based workflows for distributions and install profilesbr / Providing sub-tree splits of Drupal Corebr / Updating project pages to provide information about using Composer with any given hosted projectbr / Adding features to the updates service, to collect statistics about projects installed with Composer, and to explore providing update alerts about external dependenciesbr / We also hope to work with core maintainers to add the Composer repositories to a href= rel=nofollowDrupal Core's composer.json/a file/p pIf you're interested in learning more about our roadmap for Composer, or contributing to this service on, you can learn more in the a href= rel=nofollowComposer plan issue/a./p h3How you can help/h3 pIf you’re interested in helping to improve's support for Composer workflows, please take a look at the issue above, find us on irc in #drupal-infrastructure, or send us a a href= rel=nofollowvolunteer proposal/a./p h2Thanks to our Community Initiative contributors/h2 pWe'd like to thank the individuals who worked with us as part of this a href= rel=nofollowCommunity Initiative/ / In particular, we'd like to thank:/p ullia href=/u/seldaek rel=nofollowseldeak/a the creator of Composer and lia href=/u/webflo rel=nofollowwebflo/a the creator and maintainer of a href= rel=nofollow lia href=/u/timmillwood rel=nofollowtimmillwood/a/li lia href=/u/dixon_ rel=nofollowdixon_/a/li lia href=/u/badjava rel=nofollowbadjava/a/li lia href=/u/cweagans rel=nofollowcweagans/a/li lia href=/u/tstoeckler rel=nofollowtstoeckler/a/li /ulpWe'd also like to thank a href=/appnovation-technologies rel=nofollowAppnovation/a, who sponsored the initial development of's composer endpoints./p pTo these volunteers and sponsoring organizations—it is your expertise, your insight, and your affirmation of our work that make these Community Initiatives successful. Thank you!/p/div/div/div

Acquia Developer Center Blog: Decoupled Drupal with JSON API and Ember: Consuming Drupal with Ember Adapters and Models

Wed, 12/21/2016 - 15:14
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= width=140 height=85 alt=black hole title=black hole //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:encodedpAmong the most crucial steps in architecting decoupled Drupal-backed applications is to bridge the gap between Drupal and the designated front end so that the latter can receive and manipulate data on the Drupal data repository via API calls. For some frameworks, this can be a rather tedious exercise in navigating the server-side APIs and crafting the correct requests on the client side. Luckily, with a href= API now proposed as a core experimental module/a for Drupal 8, the tightrope walk between Drupal and Ember is about to become more of a cinch./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

Justin Winter: Drupal 8 : twig_xdebug module tutorial

Wed, 12/21/2016 - 01:00
I recently started digging into some TWIG Drupal 8 development and needed to see what variables were available to me from within the twig template. You can sometimes use KINT or print the variables to the screen but this can be really slow and doesn’t really give you the full picture. The twig_xdebug module lets you use your php debugger to inspect the variables you have access to, which can be really helpful.

Jeff Geerling's Blog: Upgrading Drupal VM in a BLT-powered project

Tue, 12/20/2016 - 21:28
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=content:encodedpLimiting the amount of surprises you get when developing a large-scale Drupal project is always a good thing. And to that end, Acquia's a href= (Build and Launch Tools) wisely chooses to leave Drupal VM alone when updating BLT itself. Updates to Drupal VM can and should be done independently of install profile and development and deployment tooling./p p style=text-align: center;img src=// width=650 height=244 alt=composer require geerlingguy/drupal-vm:~4.0 class=insert-image //p pBut this creates a conundrum: how do you upgrade Drupal VM within a project that uses BLT and has Drupal VM as one of it's composer dependencies? It's actually quite simple—and since I just did it for one of my projects, I thought I'd document the process here for future reference:/p/div/div/div

Drupal governance announcements: Provisionally approved coding standards proposals December 20, 2016

Tue, 12/20/2016 - 21:04
pThe a href= a href= standards committee/a has provisionally approved 3 coding standards change proposals. These will need to be finally approved and implemented by core before being fully ratified./p pThe process for proposing and ratifying changes is documented on the a href= standards project page/a. Please note, a a href= to this process is being proposed/a to streamline the interaction between the coding standards body, Drupal Core, and the Coder project, please provide any feedback on that issue./p h3Provisionally approved proposals awaiting core approval and implementation:/h3 ullia href= airbnb javascript coding standards/a/li lia href= a standard for @var inline variable type declarations/a/li lia href= 5.4 short array syntax coding standards/a/li /ulh3Interested in helping out?/h3 pYou can get started quickly by helping us to a href=;status%5B%5D=Openamp;issue_tags_op=%3Damp;issue_tags=Needs+issue+summary+updateupdate an issue summary or two/a or dive in and check out the a href= list of open proposals/a and see if there's anything you'd like to champion?/p pThese proposals will be re-evaluated during the next coding standards meeting currently scheduled for strongDecember 20th/strong. At that point the discussion may be extended, or if clear consensus has been reached one or more policies may be dismissed or ratified and moved to the next step in the process./p

Red Route: Adding a class to default images in Drupal 8

Tue, 12/20/2016 - 18:42
div class=field field-name-body field-type-text-with-summary field-label-hiddendiv class=field-itemsdiv class=field-item even property=schema:articleBody content:encodedpAs with many sites, images are an important part of the design for my art gallery listings site, a href= Gallery Guide/a. The tricky part is that the site is full of user-generated content, so not all of the listings have images attached./p pWhere there isn't an image, we use a placeholder - partly for our a href='tiles' design pattern/a, but also because the image is an integral part of the design for an individual listing on large screens. On a small screen, this placeholder image takes up a lot of space, and doesn't add much, so I wanted to hide it at a certain breakpoint./p pIt took me a while to get my head around how to get into the right place to be able to do this in Drupal 8, following my old standby of sprinkling my code with a href= statements (replaced in D8 with a href= I should really have cracked out a href=, but it does slow things down quite a bit, and I was too lazy to uncomment a few lines in php.ini. In this case it would have definitely made sense, because the kint output was so large that it slowed my browser down to a crawl - probably because I hadn't previously read a href= DrupalEasy article/a./p pHaving looked at the variables in scope inside codetemplate_preprocess_field/code, I saw that the relevant object was an instance of the class codeFileFieldItemList/code, which extends codeEntityReferenceFieldItemList/code. This is a good example of where a good IDE like a href= can really help - having found the class, I could quickly navigate to its parent, and see its methods - in this case the relevant one was a href= precode class=language-php/** * Implements hook_preprocess_field(). */ function mytheme_preprocess_field(amp;$variables, $hook) { switch ($variables['element']['#field_name']) { // Machine name of the field case 'field_image': // If this is the default image, add a class. $images = $variables['element']['#items']-gt;referencedEntities(); if (empty($images)) { $variables['attributes']['class'][] = 'image__default'; } break; } } /code/pre pOnce that class has been added, we can apply CSS to it - in my case it's in a SASS mixin that gets applied to a few different elements:/p precode class=language-scss@mixin image-main { amp;.image__default img { @include breakpoint($mobile-only) { display: none; } } } /code/pre pHere's an example on the live site of a href= listing with no image uploaded/a, and by comparison, a href= listing with an image/a - as you can see, the design wouldn't work on large screens if the placeholder image wasn't there, but on small screens the placeholder just takes up space without giving the user anything worth looking at./p pThe solution isn't perfect, because the browser will still download the image, even if it's set to codedisplay: none/code, as a href= Kadlec wrote about a while ago/a. But it'll do for a side project.../p /div/div/divdiv class=field field-name-taxonomy-vocabulary-4 field-type-taxonomy-term-reference field-label-above div class=field-labelTags:nbsp;/div div class=field-items div class=field-item evena href=/category/tags/drupal typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=Drupal/a/div div class=field-item odda href=/category/tags/drupal-8 typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=Drupal 8/a/div div class=field-item evena href=/category/tags/gallery-guide typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=The Gallery Guide/a/div div class=field-item odda href=/category/tags/theming typeof=skos:Concept property=rdfs:label skos:prefLabel datatype=theming/a/div /div /div a href=/blog/terms class=taxonomy-link-allAll tags/a span rel=schema:url resource=/articles/adding-class-default-images-drupal-8 class=rdf-meta element-hidden/spanspan property=schema:name content=Adding a class to default images in Drupal 8 class=rdf-meta element-hidden/span Multiple MailChimp Accounts with Drupal

Tue, 12/20/2016 - 18:33
span property=schema:name data-quickedit-field-id=node/9/title/en/rss class=field field--name-title field--type-string field--label-hiddenMultiple MailChimp Accounts with Drupal/span div property=schema:text data-quickedit-field-id=node/9/body/en/rss class=clearfix text-formatted field field--name-body field--type-text-with-summary field--label-hidden field__itempA couple of months ago, a href= ThinkShout/a quietly introduced a feature to the a href= module/a that some of us have really wanted for a long time—the ability to support multiple MailChimp accounts from a single Drupal installation. This happened, in part, after I reached out to them on behalf of the stakeholders at Cornell University's ILR School, where I work./p/div span data-quickedit-field-id=node/9/uid/en/rss rel=schema:author class=field field--name-uid field--type-entity-reference field--label-hiddenspan lang= about=/user/2 typeof=schema:Person property=schema:name datatype=aaron/span/span span property=schema:dateCreated content=2016-12-20T17:33:14+00:00 data-quickedit-field-id=node/9/created/en/rss class=field field--name-created field--type-created field--label-hiddenTue, 12/20/2016 - 11:33/span

Mediacurrent: Migrating Content References in Drupal 8

Tue, 12/20/2016 - 18:18
img typeof=foaf:Image src= width=200 height=152 alt=Drupal bits and bytes title=Drupal bits and bytes / h3 dir=ltrspanAn Introduction to Stubs/span/h3 p dir=ltrspanA common need in our projects is the ability to migrate data that references other content. This can be in the form of taxonomy hierarchy (i.e. parent gt; child relationship) or content that is attached such as images, videos, or other nodes that exist as standalone entities in the system./span/p