KnackForge: How to update Drupal 8 core?

Planet Drupal - Sat, 2018/03/24 - 6:01am
How to update Drupal 8 core?

Let's see how to update your Drupal site between 8.x.x minor and patch versions. For example, from 8.1.2 to 8.1.3, or from 8.3.5 to 8.4.0. I hope this will help you.

  • If you are upgrading to Drupal version x.y.z

           x -> is known as the major version number

           y -> is known as the minor version number

           z -> is known as the patch version number.

Sat, 03/24/2018 - 10:31
Categories:

Valuebound: Drupal 8: How to create a custom block programatically

Planet Drupal - Mon, 2016/12/19 - 8:33am
Drupal 8: How to create a custom block programatically Jaywant.Topno Mon, 12/19/2016 - 02:33
Categories:

Valuebound: Drupal 8: Custom Block Creation programmatically

Planet Drupal - Mon, 2016/12/19 - 8:33am
Drupal 8: Custom Block Creation programmatically Jaywant.Topno Mon, 12/19/2016 - 02:33
Categories:

clemens-tolboom commented on issue ErmiyaEskandary/Slither.io-bot#207

On github - Mon, 2016/05/23 - 8:47pm
May 23, 2016 clemens-tolboom commented on issue ErmiyaEskandary/Slither.io-bot#207

Should we report server versions? worked for (my?) server version May 21 16:12 game404ee.js broken for (my?) server version May 23 19:57 game515do.js

Chromatic: Javascript Theme Functions in Drupal 7

Planet Drupal - Mon, 2016/05/23 - 6:26pm

Like it or not, sometimes you have to output HTML in javascript.

Recently, I ran across a line of code something like this while reviewing a pull-request for a client:

var inputMarkup = '<span><label data-val="' + inputText + '" for="checkbox-' + index + '" data-tid="' + tid + '">' + inputText + '</label><input type="checkbox" id="checkbox-' + index + '" data-tid="' + tid + '" data-val="' + inputText + '" /></span>';

Aside from the fact that this code was hard to read (and therefore would be more difficult to maintain), the same code was used with no significant modification in three separate locations in the pull-request.

In PHP, most developers familiar with Drupal would immediately reach for one of the well-known parts of Drupal's theme system, render arrays, theme(), or a *.tpl.php file. In javascript, however, I seldom see much use of Drupal 7's extensive javascript API (also made available in a nicely browseable--though not quite up-to-date--form by nod_).

In this case, the relatively difficult-to-read code, combined with the fact that it was repeated several times across more than one file were clear signs that it should be placed into a theme function.

The Drupal.theme() function in the javascript API works much like theme() in PHP. When using theming functions in PHP, we never call them directly, instead using the theme() function.

In javascript, it's similar; when output is required from a given theme function, we call Drupal.theme() with the name of the theme function required, and any variable(s) it requires.

For example, drupal.org shows the following usage:

Drupal.theme('myThemeFunction', 50, 100, 500);

The example uses Drupal.theme() to call the theme function, myThemeFunction(), and pass it the arguments it requires (50, 100, and 500 in this instance). A theme function can accept whatever number of arguments is necessary, but if your theme function requires more than one parameter, it's good practice to define the function to take a single javascript object containing the parameters required by the function.

So in the case of my code-review, I suggested we use a theme function like this:

/** * Provides a checkbox and label wrapped in a span. * * @param {object} settings * Configuration object for function. * @param {int} settings.index * A numeric index, used for creating an `id` attribute and corresponding * `for` attribute. * @param {string} settings.inputText * The text to display as the label text and in various attributes. * @param {int} settings.tid * A Drupal term id. * * @return {string} * A string of HTML with a checkbox and label enclosed by a span. */ Drupal.theme.checkboxMarkup = function(settings) { "use strict"; var checkboxId = 'checkbox-' + settings.index; var inputText = Drupal.checkPlain(settings.inputText); var checkboxMarkup = ''; // Assemble the markup--string manipulation is fast, but if this needs // to become more complex, we can switch to creating dom elements. checkboxMarkup += '<span>'; checkboxMarkup += '<label data-val="' + inputText + '" for="' + checkboxId + '" data-tid="' + settings.tid + '">'; checkboxMarkup += inputText; checkboxMarkup += '</label>'; checkboxMarkup += '<input type="checkbox" value="' + inputText + '" id="' + checkboxId + '" data-tid="' + settings.tid + '" data-val="' + inputText + '">'; checkboxMarkup += '</span>'; return checkboxMarkup; };

This allowed the calling code to be much simpler:

// Creates themed checkbox. checkboxMarkup = Drupal.theme('checkboxMarkup', { index: i, inputText: $('.inputText').val(), tid: $('.tid') }); $container.append(checkboxMarkup);

The HTML generation is now also more loosely coupled, and more portable, meaning that we can easily use Drupal.theme.checkboxMarkup() elsewhere in this project--or in any other Drupal project.

Categories:

Sooper Drupal Themes: Beta: Revolutionary (Free) Drupal Installation Tool. SooperThemes Rebranding. Glazed & Carbide .10 Releases

Planet Drupal - Mon, 2016/05/23 - 4:25pm

Introducing Zero-Touch Drupal Product Provisioning

2 years ago I started working on a Drupal CMS distribution that makes it less painful to launch a fully configured Drupal website. Today we're proudly launching what I think is the best CMS installation experience you've ever seen. Pantheon and Acquia cloud might be great tools for people like me who work with Drupal on a daily basis, but there is a huge community of people who need something more simple. Our goal was for users to install a fully configured and themed Drupal website, with fully configured CMS components and demo content without requiring any user interaction.

Our Deployment tool currently does the following completely on auto-pilot:

  1. Runs tests to see if the receiving server ready for installation
  2. Generates a custom build of our Glazed CMS installation profile with the CMS components you need
  3. Uploads the files straight from sooperthemes.com to your server
  4. Uses Drush to go through the entire installation on your server
  5. Installs demo content

Looking For Drupal Hosting Partners

From a wider perspective, I see this kind of service as an answer for the Open Web to the streamlined experiences provided by companies like Wix and SquareSpace. The walled garden alternatives for small businesses. In that light want to integrate with as many great Drupal hosting providers as possible. The first Hosting partner I integrated is A2hosting, because they provide SSH and Drush automatically to all users. I'm looking for other hosting providers who offer this, if you know of, or are such a company please let me know in the comments.

Our service launched in beta but theoritically this should work fine on an Drupal/Drush capable server. It doesn't matter if you run Apache with MySLQ or nginx with PostgreSQL, our software has only the following server requirements:

  • Drupal capable stack
  • Drush
  • Rsync
  • SSH with password authentication
Looking For Testers

This means you can try it out right now on your VPS development server, all you need to provide is an empty web directory and database. If you're trying this and can't get it to work on your Drupal/Drush capable server please let me know in the comments. We did a lot of testing but the variety of server configurations is so vast that I'm sure we can improve our software's compatibility. Just to be clear, you don't need to be a subscriber or even registered on sooperthemes.com to use this. As a guest user you cannot choose the premium themes in the form but you can install any configuration of our CMS distribution with the Glazed Free theme.

It has been an adventure developing this new deployment tool. If you are excited too please test it and let me know what you think!

In Other News: SooperThemes Rebranding. Glazed 2.4.10 and Carbide Builder 1.0.10 Released

This week I've also updated the SooperThemes logo. For the past year the sooperthemes.com website has reflected what our new product was: Completely new and finding out where it wants to go. Now the logo more reflects the values of simplicity, open source and friendliness. These are the values I want to embed in our products. The logo is much simpler than the old one. The openings in the O are for open source. And the last detail is the Happy e's. This little touch of Dutch Design is a tilted back lower case e, it was invented by Heineken and reminds of a laughing head.

Today you can also download the latest patch-level release of Glazed theme and Carbide Builder. These releases contain no new features, only bug fixes. See the Glazed CHANGELOG and Carbide CHANGELOG. We've also updated the YouTube background library and put a usage example in the bottom of the Sections and Backgrounds demo page. Enjoy!

Categories:

Virtuoso Performance: Global migration sprint day - Monday May 23

Planet Drupal - Sun, 2016/05/22 - 6:47pm
Global migration sprint day - Monday May 23

As I wrote in my last blog post, I'd like to try doing regular sprint days for Drupal 8 migration. These will be a bit more informal than than a conference sprint - basically, a day when anyone interested in helping move the migration system from its experimental status to a fully supported subsystem of Drupal core can show up in #drupal-migrate, or just pick a relevant issue and start working on it. Our theme for at least the first of these sprints is migrate-critical issues - these are issues for the migration system which would be marked critical if the system were full supported, and thus our highest priority to address. Some issues need code written, some need tests written, some could use code review and/or manual testing, and some need discussion around the best approaches - there are multiple ways to help out.

If you're interested in contributing to the sprint, on Monday May 23:

  1. Check the triaged list of issues - if you find one you'd like to work on, add your drupal.org username under "Who's working on it". The fact that someone is doing work on a given issue doesn't mean you can't help too - virtually any issue without a stable patch could use input and suggestions, and any issue with a patch could use review and manual testing.
  2. Join #drupal-migrate on IRC. Get help selecting an issue to work on, coordinate with others on a given issue, ask general migration questions (or answer them!), ...
  3. If writing or testing code for a given issue, pay attention to which Drupal core version the issue is filed against (generally it'll be 8.1.x for bug fixes, and 8.2.x for new work) and be sure you pull the correct core branch to work against.

I expect to be available in #drupal-migrate for most of the time from around 9am to (at least) 6pm U.S. Central time (minus a lunch break). You can expect to find other people with migration expertise there at most times, of course.

mikeryan Sun, 05/22/2016 - 11:47 Tags
Categories:

FFW Agency: Great Examples Of Distributed Content Management In Product Companies

Planet Drupal - Fri, 2016/05/20 - 7:24pm
Great Examples Of Distributed Content Management In Product Companies erik.wagner Fri, 05/20/2016 - 17:24

Welcome to the fifth post in my series on Distributed Content Management.  In previous posts I’ve defined the concept and provided some great examples of Distributed Content Management use cases in higher education, the pharmaceutical industry and media and entertainment companies.  In today’s post I’ll wrap up my industry-specific use cases by investigating ways in which product companies can use Distributed Content Management to improve their approach to everything from internationalization of their websites to managing community contributions. 

Setting The Scene

Product websites, whether for physical or virtual products, must ultimately influence their visitors.  For direct-to-consumer products, the goal may be a direct conversion - to get the visitor to buy/download the product.  Business-to-business products often have a more complex buyer’s journey, starting with something as seemingly minimal as driving the visitor to contact the company for more information.  Within the digital sphere, companies whose products are extensible platforms or systems may be seeking not only end-users, but developers or contributors to expand on the value of their initial offerings.  In all of these scenarios, the content presented to the user must be keenly adapted to the task at hand and, with products especially, must co-exist with information available from external sources.  Carefully planning their approach to Distributed Content Management - to the point of expanding what they may consider content - is a key tool for a product company’s success.

Use Case 1: A Multi-System Approach to Product Experience Management

Many web platforms strive to be all-in-one solutions for a product’s online presence; however, savvy product companies recognize that they can build a superior web experience by integrating multiple systems and relying on their core strengths.  A common example of this for product companies is around enterprise e-commerce systems (such as Demandware, Magento, or BigCommerce).  All of these solutions provide some level of content management and layout control; however, larger organizations that make heavy use of Distributed Content Management staples such as content re-use and custom publishing workflows may find the out-of-the-box tools duplicative or not sophisticated enough for their processes. Luckily, these systems allow organizations to interact with them programmatically through APIs and many provide pre-built connectors to popular content management systems such as Drupal and WordPress.  By integrating e-commerce tools with powerful content management systems, product companies can have the best of both worlds for both their internal processes and customers’ experience.

Use Case 2: Internationalization of Product Websites

Entry-level internationalization may be achieved with a single website and automated text translation; however, as a product company’s reach expands so may the sophistication of their internationalization strategy - and that can impact their needs for Distributed Content Management.  A simple example of this may be the transition between automatic translation technology (such as Google Translate, Lingotek Inside or Translate.com’s Website Translator) and content management provided by native-speaking editors.  Native-language content production, with its cultural nuances and idiomatic expressions, can provide a far superior experience to a website’s visitors but introduces a number of elements to a company’s Distributed Content Management strategy. For example, how will translated content fit within the company’s existing publishing workflow?  How will different language teams coordinate around new pages and content?  Taking this further, companies that produce physical products often have unique product lines in different geographical regions, a reality that necessitates a decentralized management strategy with close coordination around company-wide content.

Use Case 3: Curating Other People’s Content

More so than ever before, potential customers have easy access to a flood of content about a product before they decide whether or not to use it.  For a company’s digitally-inclined customers, Amazon’s Q&A and reviews, YouTube videos and even social media interactions with a company have become key elements guiding their decision making.  Attentive product companies actively manage these external sources: answering questions on Amazon, providing high-profile bloggers and YouTube producers with review copies of products, etc., but companies interested in further differentiating themselves are beginning to recognize that the content produced on these channels should be part of their Distributed Content Management strategy.  For example, Twitter actively promotes itself as a customer service platform, citing not only its “unparalleled reach,” but the fact that its conversations can be “embedded across other media.” However, many content strategists promote this same approach for curating testimonials.  Curating and embedding tweets in which a user speaks positively about a company’s product is a great example of managing distributed content to increase potential buyers’ social trust in a product.

Use Case 4: Content For Contributors and Existing Customers

Prospective users are not the only audience for product companies.  Physical product companies, especially those making electronics, often provide access to support resources, such as frequently asked questions and downloadable product manuals. Companies that produce digital products may offer software downloads and updates or, in the case of open products, API and developer documentation.  With each of these areas comes important decision around a company’s approach to Distributed Content Management.  Will product support require registration?  If so, what external system integrations are required to share the appropriate content with the user?  Will developers be able to contribute documentation?  If so, what kind of publishing workflows will be in place in for community-contributed content?  While each new audience brings additional considerations around Distributed Content Management, it also increases the opportunities to improve a product’s digital experience and extend its reach.

What’s Next?

Now that we have sufficiently explored industry-specific use cases for Distributed Content Management, I’ll move on to discussing prerequisites for proper planning.  Thoughts or questions?  Reach out in the comments below or tweet them to me at @HankVanZile.

Tagged with Comments
Categories:

Four Kitchens: Trip Report: DrupalCon 2016 — Five Days in New Orleans

Planet Drupal - Fri, 2016/05/20 - 6:14pm

A mostly full report on what went down last week in the Big Easy, gonzo journalism -style. …

Categories:

Texas Creative: First Impressions During a Drupal 8 Website Build

Planet Drupal - Fri, 2016/05/20 - 3:00pm

It’s Official!  We have finished setting up the necessary infrastructure and processes for building client sites in Drupal 8 moving forward.  A lot of that work was done during our first Drupal 8 website build, which is nearing completion.  What follows is a brief glance of my first impressions and future aspirations about Drupal 8 development.

The Project

As website builds worked their way through the pipeline in the first part of 2016, I was on the lookout for the right one to be our first D8 site.  The project I chose is a portal for this company’s contractors to log their daily activity out in the field.  The portal also generates various reports from the activity for our client to use.  This project is unique in a couple of different ways that makes it the clear choice for our first foray into Drupal 8:

Read More
Categories:

Cheppers blog: Knowledge base for DrupalCamp organizers

Planet Drupal - Fri, 2016/05/20 - 10:05am

This year, at DrupalCon New Orleans I was lucky to attend the best community summit I’ve ever been to, with a bunch of great people who were really interested in topics how to grow the Drupal community. As a result of the discussions we had, we decided to start a knowledge base for Drupal event organizers to collect and share tips and tricks. Keep reading to find out more information about the initiative.

Categories:

Jeff Geerling's Blog: Drupal VM 3 is here!

Planet Drupal - Thu, 2016/05/19 - 11:33pm

Drupal VM 3.0.0 "The Light Sailer" was just released, and you can grab it from the Drupal VM website now. We spent a lot of time during DrupalCon New Orleans sprinting on Drupal VM, fixing bugs, and updating ALL THE THINGS to make sure this release solves a lot of pain points for individuals and teams who need a great local development environment.

Let's get right into why this is the best release of Drupal VM EVER!

The fastest and most modern environment

Drupal VM now defaults to Ubuntu 16.04 (which was just released in late April), running MySQL 5.7 and PHP 7. This means you're getting the fastest, most reliable, and most modern development environment for your Drupal 8 projects.

Categories:

Lullabot: DrupalCon New Orleans Wrap–up

Planet Drupal - Thu, 2016/05/19 - 10:00pm
Matt & Mike talk with a gaggle of Lullabots about their experiences at DrupalCon New Orleans.
Categories:

Palantir: Top 5 Takeaways from DrupalCon New Orleans

Planet Drupal - Thu, 2016/05/19 - 9:36pm

DrupalCon New Orleans was last week, and it kept us quite busy! Even though we all thoroughly enjoyed the conference and socializing that came with it, now that we've had a few days to reflect, our memories are even fonder. With that, we share our top 5 takeaways from DrupalCon.

5) Drupal 8 is coming into its own

It's no secret that the long development cycle of Drupal 8 created uncertainty for some organizations and agencies alike. But that's all a distant memory now. We saw a significant uptick on the adoption of and migration to Drupal 8 at this year's DrupalCon, and we couldn't be happier. Better still, our hard work on Drupal 8 – in working with Drupal 8 for our clients, contributing to core, as well as helping bring Workbench to Drupal 8 – means we're well suited to take on your Drupal 8 project or provide expert advice on whether or not it's time to migrate based on your organizational goals. Interested in learning more? Let's talk.

4) The sessions and keynotes

Regardless of your area of expertise, this DrupalCon provided a wide range of incredible sessions and daily keynotes; some technical, some about strategy, some about making the workplace better, and everything between. Both Engineer Kelsey Bentham and Account Manager Allison Manley enjoyed Easy Accessibility in Drupal 8. Our Director of Professional Services Ken Rickard enjoyed Jeff Eaton's Recoupling: Bridging Design and Structured Content session and what Dries shared about the Content Workflow initiative. Our Director of Operations Colleen Carroll loved Leaving Drupal by David Hwang (it has a happy ending, promise). Whereas Senior Engineer Andrea Soper stuck to conversations in the hall and hallways where she appreciated the hard work getting the Contrib modules updated for Drupal 8, and that there were frank discussions about work/life balance and the health of team members in both the community and workplace. The list could go on, of course, so let's continue it. Which sessions or keynotes did you enjoy most? Let us know in the comments, or on Twitter @palantir.

3) Workbench!

This indispensable module is ready for Drupal 8 right now, with its component modules closely behind. We talked with a lot of folks about Workbench, and the excitement at DrupalCon was clear. In fact, if you're a user of Workbench in Drupal 7, or are Workbench-curious, we're hosting a free webinar next week as a intro to Workbench in Drupal 8. Sign up right here, and spread the word!

Want to learn more about Workbench for Drupal 8? We're hosting a free webinar on May 24th at 1:00pm CDT, and would love for you to join us. 2) The overall positivity

We'll admit that this is pretty hand-wavey, but if you were there you'd feel it, too. There was a lot of positivity about Drupal this year, proven by those who work on Drupal as a platform, organizations who use Drupal, and even those who are considering Drupal. Virtually everyone we spoke to agreed, and, in fact, some shared such thoughts in our Best of DrupalCon podcast by Account Manager Allison Manley. Don't believe us? Give it a listen!

iTunes | RSS Feed | Download 1) The community

We've said it before, and we'll say it again: as far as Drupal has come as a top choice for countless organizations, it's the community that makes it all possible. DrupalCon truly is a place to learn, share, and, of course, socialize with some of the best and brightest people working in Drupal, and beyond. Thank you for the great times, and even greater conversations.

See you next year!

Missed us at DrupalCon, but want to chat about your project? Let's schedule a time to talk.

Dries image by Susan Coates - Attribution-ShareAlike 2.0 Generic (CC BY-SA 2.0) on Flickr

Categories:

Acquia Developer Center Blog: Migrate to Drupal 8: A How-To Scan

Planet Drupal - Thu, 2016/05/19 - 9:31pm

Can we all agree that it's too early for any kind of definitive guide to Drupal 8 migration?

I think we can, so I won't pretend to wrap up the topic with a neat bow on top.

Whether your starting point is D6 or D7, it's still an adventure to move a site to D8.

It's getting better all the time, of course: hackathon by hackathon. Which means that it's not too soon to get something started to help us all focus on this inevitable task.

Tags: acquia drupal planet
Categories:

DrupalEasy: DrupalEasy Podcast: New Orleans Day 2

Planet Drupal - Thu, 2016/05/19 - 7:35pm

Direct .mp3 file download.

Hosts Ryan Price, Mike Anello, Kelley Curry and Anna Kalata are joined by guests Suzanne Dergacheva (of Evolving Web) Dave Hall (of the newly anointed Drupal 8 Workflow Initiative) and Steve Edwards to discuss Day 2 of DrupalCon. Ryan also breaks into interviews with Symfony's creator, Fabien Potencier, and the local New Orleans Drupal community representative, Eric Schmidt. Finally we hear some fun non-Drupal things each panelist did in the week.

Check in later this week for more episodes from DrupalCon New Orleans 2016.

Follow us on Twitter Intro Music

Glory Glory Code of Conduct from #Prenote

By Adam Juran, Campbell Vertesi and Jeremy "JAM" Macguire

Subscribe

Subscribe to our podcast on iTunesGoogle Play or Miro. Listen to our podcast on Stitcher.

If you'd like to leave us a voicemail, call 321-396-2340. Please keep in mind that we might play your voicemail during one of our future podcasts. Feel free to call in with suggestions, rants, questions, or corrections. If you'd rather just send us an email, please use our contact page.

Categories:

ImageX Media: Managing the Creative Process

Planet Drupal - Thu, 2016/05/19 - 6:48pm

Inherent in the design process is the debate between subjective and objective quality. Can a design be called objectively “good” and, if so, what is it that makes it good? Or is the quality of a design entirely in the subjective eye of the beholder? However, implicit in this debate is the assumption that design is a single thing that can be viewed as a whole, rather than different elements that each play a role in the overall user experience. 

Categories:

Platform.sh: Automatically sanitize your database on development environments

Planet Drupal - Thu, 2016/05/19 - 5:01pm

You’re developing your site on Platform.sh and you love the fact that you get exact copies of your production site for every Git branch that you push.

But now that you think about it, you realize that all those copies used by your development team to implement new features or fixes contain production data (like user emails, user passwords…). And that all the people working on the project will have access to that sensitive data.

So you come up with the idea to write a custom script to automatically sanitize the production data every time you copy the production site or synchronize your development environments. Next you think of a way to automatically run that script. Possibly a custom Jenkins job that you will maintain yourself. But, of course, you will need to update this Jenkins job for every new project you work on. Plus, you will have to figure out the permissions for this script to give proper access to your site.

But wait, what if I told you that all this hassle can be handled in a simple deployment hook that Platform.sh provides?

Categories: