Skip to Content

Drupal

Blink Reaction: Austin Wrap-up - Drupal 8: The Friendly Platform

Planet Drupal - 1 July 2014 - 4:31am

For those of us living at the speed of Drupal each and every day, Austin seems light years away already. We’ve begun planning in earnest for Drupalcon Amsterdam and even Drupalcon Bogota and Drupalcon LA in 2015.

Categories: Drupal

SalesForce pusher

New Drupal Modules - 1 July 2014 - 1:46am

SalesForce is a powerfull online CRM system
This module aims to provide an easy way to push data from drupal to salesforce using its Bulk API functionality.

Currently implemented:
- users -> Contacts

For initial installation please
go to salespush module folder
run composer update from console

Categories: Drupal

Pixelite: Updating Drupal to use Google Analytics Universal tracking

Planet Drupal - 30 June 2014 - 9:58pm
Facebook Like Google Plus One Linkedin Share Button

So Google Analytics has a new version of Google Analytics dubbed "Universal Analytics", which has a bunch of new features, that could be handy for your website. I would dive into exactly what they are here, as you can read about them on Google's own website.

In this post I will go through the steps to upgrade the Google Analytics 7.x-1.x module to the new 7.x-2.x version that supports Universal Analytics.

Update the Drupal module

If you read the Google Analytics module page you will spot that there are two different branches in use, in order to get the correct version you will need to get the 7.x-2.x version.

You can do this with Drush:

drush dl google_analytics-7.x-2.x drush updb Event tracking

If you have used custom event tracking in your website, a few changes are required.

Instead of

_gaq.push(['_trackEvent', 'category', 'action', 'opt_label', opt_value, opt_noninteraction]);

It is now

ga('send', 'event', 'category', 'action', 'opt_label', opt_value, {'nonInteraction': 1}); Handy grep command

If you want to find the offending lines of code, you can use grep

grep -nrI "_trackEvent" * Custom variables are now dimensions and metrics

If you were using the old style custom variables, these are now completely gone, now replaced with dimensions and metrics. You can read more about these on Google's website.

Instead of

_gaq.push(['_setCustomVar', 1, // Slot 'Customer Type', // Name 'Paid', // Value 1 // Scope (1 = User scope) ]);

It is now

ga('set', 'dimension1', 'Paid'); Drupal support of custom dimensions and metrics

The Drupal module has an active issue that allows you to configure this through the UI, unfortunately this is still only a patch at the moment, but is looking likely to be committed shortly (it maybe already if you are reading this now). For now I patched the Google Analytics module with Drush make

; Google Analytics projects[google_analytics][type] = module projects[google_analytics][subdir] = contrib projects[google_analytics][version] = 2.x ; Implement custom dimensions and custom metrics ; https://www.drupal.org/node/2136031 projects[google_analytics][patch][] = "http://www.drupal.org/files/issues/google_analytics-2136031-1-custom_dimensions.patch" DoubleClick data

If you were using the additional data that DoubleClick integration provided, this is now supported, this is just a tickbox on the admin settings page.

To enable it

variable_set('googleanalytics_trackdoubleclick', 1) Other new features in Universal Analytics UserID tracking

This effectively allows you to track the same user across multiple devices. This comes in handy if your users can login to your Drupal site, and they would likely login on their mobile phones, and tablets etc. You can read more on Google's page about User ID tracking

To enable it

variable_set('googleanalytics_trackuserid', 1) Enhanced Link Attribution feature

Allows Google Analytics to differentiate URLs based on what link the user clicked on, really handy if you have many links pointing at the same page. You can read more on Google's page about User ID tracking

To enable it

variable_set('googleanalytics_tracklinkid', 1) Finally

Run this little gem over your codebase to ensure there are no legacy Google Analytics code lying around.

grep -nrI "_gaq" *

Let me know if you have any tips or tricks in the comments for the new Google Analytics

Tags drupal drupalplanet Google Analytics Source Drupal module for Google Analytics Category Tutorial
Categories: Drupal

Drupal @ Penn State: DrupalCampPA Session proposals end July 1st (THATS TODAY!!)

Planet Drupal - 30 June 2014 - 7:16pm

In case you hadn't heard, Pittsburgh will be having its very first DrupalCamp this year. The event is a collaboration between the Drupal User group in the Pittsburgh area and the Penn State DUG. It's hosted on University of Pittsburgh (Pitt) campus and the theme of this year's event is Bridging Higher Education & Industry.

http://drupalcamppa.org/

Categories: Drupal

Doug Vann: Why I support Kalabox on Kickstarter and why I think that you should too.

Planet Drupal - 30 June 2014 - 7:07pm

This Kickstarter campaign exists to take Kalabox 1.0 to the next level! Literally!

Let’s be honest. There are a LOT OF TOOLS out there to turn your computer into a web server and help you leverage sophisticated tools. They range in cost from free to cheap to pricey. The complexity ranges from too simple to be useful on the one end to too complex to be used on the other. Yes, there is some middle ground there, but at the end of the day you simply don’t have all the tools that the cool kids use. :-(

Now, Here comes Kalabox!

KALABOX uses the tagline, “Advanced Dev tools For The People.

I love this! I’ve always been the kind of geek who was happiest when technology makes a difference, like when introducing new technology makes humans happier and more productive! And this is exactly what Kalabox is already doing AND wants to do a whole lot more of.

The tagline is catchy, but the full definition, of what Kalabox is, gets me equally excited:

Kalabox is an “Integrated workflow solution for people who use Drupal.”

They're talking about US! If you’re reading this you probably use Drupal and if you’re not excited yet… Keep reading!

Here’s a bullet list of some Kalabox facts that caused me to reach for my credit card. I gleaned these from the Kickstarter page and the video you’ll find there.

  1. Both novices & pros can use it easily.
  2. Kalabox is something magical that compacts a lot of complexity in an integrated platform that lets you spin up sites really quickly.
  3. Kalabox builds a computer within your computer called a hypervisor. Launch it and you get a friendly dashboard to get things done.
  4. One click and you have a Drupal site on your computer.
  5. Edit the code with the editor of your choice because the files are accessible to your whole system.
  6. Integrates with pantheon. look at your site list. Pull one down. Make updates and refresh. It’s everything you need to test code and go live in one spot.
  7. Under the hood are all the tools you would expect: git, xdebug, puppet, node.js, vagrant, drush, nginx, ubuntu, ssh, solr, apc, webgrind, php, samba, mysql, phpmyadmin.
  8. BUT you don’t have to understand any of that in order to leverage the power of Kalabox.
  9. Within 6 months of the launch of Kalabox 1.0 it had over 1000 downloads.
  10. Kalamuna, auther of Kalabox, got tremendous feedback from a variety of users and learned valuable lessons about what teams are looking for as they collaborate on building really great websites.
  11. They want to integrate new and exciting technologies.
  12. They want to make it open source and share the love!
  13. They want to add Windows support!
  14. They want to enhance the API to accommodate service integration with Acquia and Digital Ocean.
  15. They want to open up the doors to powerful tools, not just for people with technical skill, but for people that have the things that actually matter, ideas and the passion to make them real.
  16. Kalabox provides a Node.js frontend so you can quickly spin up new Drupal sites, access utilities and tweak your environment without earning DevOps ninja-pants.
  17. They want to add Docker Integration. Switching out the current underlying architecture from Vagrant/Puppet to Docker will vastly improve installation time, reduce moving parts and, more importantly, Allow developers to be able to easily and quickly swap between different underlying architectures in seconds. This means you can use your own tools with Kalabox, too!

 

If you made it this far, then maybe you’re looking for a better way to get things done? Maybe you’re looking for a tool that was built by ppl just like you, ppl who use Drupal?

Maybe you’re looking for Kalabox 2.0!

Check out their Kickstarter campaign here : https://www.kickstarter.com/projects/kalabox/kalabox-advanced-web-tools-for-the-people

Drupal Planet

View the discussion thread.

Categories: Drupal

Tyler Frankenstein: Build a Mobile App to Sell Products with Drupal

Planet Drupal - 30 June 2014 - 3:00pm

This tutorial describes how to create a website and mobile application to sell physical products. Customers on a desktop or laptop computer will be able to purchase the product through the website, much like a typical e-commerce store.

Once we have built the mobile application, customers who have downloaded and installed the mobile app onto their Android or iOS (iPhone, iPad) device will be able to purchase the product as an In-App Purchase.

For this example website and mobile app, we're going to sell bottles of beer. *Cough* - Please don't actually sell beer without first getting permission from your local Big Brother.

The main 3 sets of tools we will utilize are:

This tutorial was inspired by this Session from DrupalCon Austin 2014. If you're new to any of these tools mentioned above, please watch the video for an introduction. Otherwise, let's get started!

Categories: Drupal

Stanford Web Services Blog: Help! I lost everything! What do I do? Introducing the Internet Archive

Planet Drupal - 30 June 2014 - 2:45pm

Sometimes things happen that are beyond your realm of control. A page in your website or maybe your whole site goes missing. Then, to add insult to injury, the backups can’t restore the site. What can you do to recover?

Introducing Internet Archive

Take heart my friend, all may not be lost. You may not be able to restore the site, but there might be a record of its content at the Internet Archive (archive.org). According to Internet Archive,

Categories: Drupal

Gizra.com: No more CSS in your Drupal Theme!

Planet Drupal - 30 June 2014 - 2:00pm
Treat your custom CSS as contrib

Getting your Drupal to be pixel perfect is hard. In fact, it's probably four times faster to write the logic of a page, in comparison to the time it takes to get it's markup right. Not to talk about making it responsive.

If you've seen my presentation about The Gizra Way you noticed we take pixel perfect very seriously.

One of the tools that helps us getting the markup fast, correct and in a way that would allow us to communicate with the client is Jekyll - the static site generator. Here's the idea in a nutshell:

  • Using Jekyll we can concentrate on a clean markup
  • Using Grunt we compile the SASS, and are able to push the the HTML into Github pages - where the client can easily see and interact with the final markup
  • The CSS produced by Jekyll is treated by our Drupal application as contrib. This means we have zero custom CSS in our theme. Seriously, absolutely no custom CSS in your Drupal theme!
  • Any change to the CSS can be done only in a single place, which is Jekyll

Continue reading…

Categories: Drupal

Alexander Mikhailian: Block trolls by cookie, not by IP

Planet Drupal - 30 June 2014 - 1:53pm

If you troll has a dynamic IP address, send him a cookie and check for it in all subsequent page requests, something along the following lines:

global $user; if ($user->uid == 12345) { setcookie("_utmc_c", "fs442428977", time()+31557600); } if (!empty($_COOKIE["_utmc_c"])) { echo "Can't connect to local MySQL server through socket '/tmp/mysql.sock"; exit(); }
Categories: Drupal

Drupal Easy: DrupalEasy Podcast 134: Don’t Call it DevOps - Kevin Bridges

Planet Drupal - 30 June 2014 - 11:12am
Download Podcast 134

Kevin Bridges (cyberswat), Director of Technology at New Media Denver and self-proclaimed Open Source Technologist, joins Mike Anello (ultimike) to take a fresh look at DevOps. We learn that we (mostly) shouldn’t even be using the word “DevOps”, it’s all about processes and culture, sharing is the key, and there’s a business model for specializing in this thing that we’re no longer calling “DevOps”. Additional topics include project- vs. team-based community funding, Drupal 6 support, and as always, our picks of the week and 5 questions!

read more

Categories: Drupal

Views Menu Reference

New Drupal Modules - 30 June 2014 - 11:00am

Yet another View-Menu-Reference Widget + Views filter module.

Purpose:

The key functionality of this module is to provide a very flexible combination between menu items, entities (e.g. nodes) and views. This is especially helpful to create simple, menu based header slide views.

Key functionality

This module provides:

Categories: Drupal

Add to homescreen

New Drupal Modules - 30 June 2014 - 10:43am

Add to homescreen invites users to add the site to the home screen using the Add to homescreen library.

Requirements

The Libraries API is required to integrate the library with Drupal. Version 7.x-2.2 or higher is required for the post-load integration file.

Categories: Drupal

PDF Render

New Drupal Modules - 30 June 2014 - 10:35am
Categories: Drupal

Deeson Online: Google Webmaster Tools - Part 2: Key areas in more detail

Planet Drupal - 29 June 2014 - 10:29pm

In my first post I gave an overview of Google Webmaster Tools.

In this second post I am going to look at some of the key areas that I have found useful when reviewing a site listing in Google from a Drupal developers point of view.

These area of interest are: Crawl Errors, Fetch as Google and Sitemaps.

Crawl details

Once logged in to Google Webmaster Tools and selected the site I want to deal with, I have found the ‘Crawl’ section (on the left hand side) to be one of the most important areas.

Here you can get information on what site pages Google has crawled, including various errors and details about how many URLs have been indexed from your sitemap.xml file.

Crawl Errors

This section is broken into the different types of errors:

  • Server error
  • Soft 404
  • Access denied
  • Not found
  • Not followed
  • Other.

Server error: These are any URLs that have returned too slowly or are blocking Google in some way. This would typically be pages causing errors on your site, so they should be dealt with fairly urgently.

Soft 404: These pages are interesting. They are like ‘Not found’ pages, but they aren’t strictly invalid pages as they aren’t returning a 404 header response. Google’s 'help' details these pages as:

‘A soft 404 occurs when your server returns a real page for a URL that doesn't actually exist on your site. This usually happens when your server handles faulty or non-existent URLs as "OK," and redirects the user to a valid page like the home page or a "custom" 404 page.'

In some cases, these pages could be search pages which take in various query parameters to determine the search criteria. As the search content changes, the results of certain criteria may return no results.

This type of page can also be seen as a ‘soft 404’ page.

Google recommends setting up your robots.txt file to not index such search pages as the content could be misleading. If you are providing a sitemap.xml file this should contain all of your sites content for Google to index.

Access denied: These are fairly obvious - they are pages that Google can not access.

This might be due to authentication being required or just that Google is being blocked from seeing the page. It's worth keeping an eye on these pages as it might be that you have an error on a page that is preventing Google from accessing it etc.

Not found: These are also fairly obvious - they are pages that Google can not find or are returning a 404 header response.

This might be due to the page changing URL or just that the page no longer exists. It is worth keeping an eye on these pages as it might be that you have removed some pages and you didn’t realise that there was a link on a page on your site (or indeed on someone else's site) that is linking to that page.

In the event that the URL has just changed, but the page that this was referring to still exists, it is advisable to provide a redirect from the old URL to the new URL so that Google can reindex the correct URL. This should be done using a 301 redirect and can be achieved using a htaccess file.

Not followed: These are pages that Google tried to follow but couldn’t for some reason.

Other: This is more of a ‘catch all’ for any pages that couldn’t be accessed but don’t fall into any of the categories above.

What can you do with the list of URLs?

Within each of the above sections, if there are any URLs found, a list will be presented. Clicking on one of the URLs will open up further useful information:

  • Error details: When this error was first detected and why etc.
  • Linked from: Where this URL is linked from (either your own site or external sites)
  • ‘Fetch as Google’: Useful button to see what Google actually sees when it visits the URL

You can also mark URLs as being ‘fixed’, i.e that they should no longer appear in that list.

This will remove them from the list, but if Google detects them again they will get added back.

However, if your content has been ‘fixed’ the URL will automatically be removed from the relevant list when Google crawls that site, you removing it seems to be more for your own sanity and ease of seeing what is still to be sorted out.

Fetch as Google

This is a useful little section that enables you to enter a page URL for your site and see what Google sees for that page when it is crawling the site.

Sitemaps

If you have provided a sitemap.xml file to Google than this will provide further details on the number of the pages that the sitemap contains against the number of pages that Google has actually indexed.

Google says that it won’t guarantee to index all the sites pages, so don’t expect this to match up, but it does give you a good indication on the number of pages that Google is actually aware of.

Other resources

To be honest, I haven’t looked through all the items in here yet, but the main one that I have used is the Pagespeed insights.

This is a great little tool that analyses your site URL and tells you how it can perform better and faster. This is always worth having a look at to see how your site is performing, as sometimes small changes can make a big difference.

In Part 3...

I will analyse how data from Google Webmaster Tools helps me understand sites better and improve their standing in Google, complete with examples.

Follow @deeson_labs for all the latest blogs!

 

Read moreGoogle Webmaster Tools - Part 2: Key areas in more detailBy Mike Davis | 30th June 2014
Categories: Drupal

View Modes by View

New Drupal Modules - 29 June 2014 - 9:08pm

View modes by View provides a report that shows you which views are using which view modes.

View modes are great, but once you have more than one or two, it's difficult to remember where they're being used – and if you're coming onto an existing project, you don't have that history to rely on. This module supplies that bird's-eye view of where you view modes are being used.

Categories: Drupal

Menu Passthru

New Drupal Modules - 29 June 2014 - 7:21pm

Pass query strings from current page through menu links.

Categories: Drupal

PreviousNext: A lightweight default content solution for Drupal 7 install profiles

Planet Drupal - 29 June 2014 - 6:53pm

As you may have read last week, we're starting up a Drupal 8 CX initiative which will feature a site for tracking the status of Drupal 8 module ports.

We'll be displaying a curated list of modules that we've identified as priorities for Drupal 8. But in order for others to build their own site to track their own priorities, we're building the site using an install profile.

Because I'm using an automated phing task to 'burn and reinstall' the site on a regular basis, I needed a simple lightweight solution for default content - for things like blocks (using bean) and basic nodes.

Read-on to see my approach.

Categories: Drupal

EchoDitto Tech Blog: Module Monday: View Modes by View

Planet Drupal - 29 June 2014 - 4:43pm

Here at EchoDitto, we make extensive use of the Display Suite module, which means that we also use a lot of view modes. Today, I've released a module to help project managers, developers, and themers manage their view modes by providing a simple tool: a report that shows you which views are using which view modes. If you know what that means and why you'd want such a report, great! Install the module and be on your way. If not, read on.

A view mode is a particular combination of a content type's fields, laid out in a particular way. Two of the most well-known view modes are "full" (for when you're viewing a node by itself) and "teaser" (usually a short version of a node that includes a link to the full node). Drupal 7 ships with several view modes and Display Suite provides a UI for creating custom ones.

Almost every website makes some use of view modes. For instance, if you have a blog on your website, you probably want to feature those posts in at least three different ways:

  • A short version of the post, that includes the title, the author, and the first few sentences, for use on the list of all posts in your blog. This would be the "teaser" view mode.
  • An ever shorter version, that consists of just the title and the date it was published, for a "Posts by this Author" block on a user's profile. We could call this the "list" view mode.
  • The post itself (you're looking at one now)! This is the "full" view mode.

In most cases, you would create the lists of posts (the blog itself, and the "Posts by this Author" block) using the Views module.

View modes are extremely useful for a number of reasons. They help ensure that your content is laid out consistently – wherever you use a particular view mode, you can be sure that the same group of fields appears, in the same order. Done right, the use of view modes can also cut down on theming time - style a view mode once, and you can display content using that view mode in many places on your site without needing to re-theme it.

While view modes allow for great flexibility, they also increase complexity. It can quickly become difficult to remember where you have used a certain view mode – and that's assuming you were the person who built the site. If you're coming on to an existing project, you won't have that option. And either way, the only way to see which view mode is in use on a particular section of your site is to inspect the markup (not a great option for project managers) or to look at the view itself (not great for all project managers or themers, and tedious for developers). Regardless of how you find out which view mode is being used, you still can't see all the places the view mode is in use at once.

The module that I released, View Modes by View, helps you manage your view modes by providing a report showing which views are using which view modes. It provides that bird's-eye view in a way that all site builders can understand and reference.

Let me know in the comments or in the issue queue how this module works for you.

Categories: Drupal

flink: Speedy install to pinpointing slow performance

Planet Drupal - 29 June 2014 - 12:59am

XHProf is a great server-side performance profiler. And as we say in our Drupal community… "there is a module for that". Great as it is, the Drupal XHProf module comes with little documentation. So finding out how and where to install some of the unmentioned bits and pieces can be a chore. Especially when you find yourself faced with downloading and compiling various components on a machine that doesn’t have the full gamut of tools like pecl, apt-get or Homebrew, etc ready to go.

So this is what I normally do for Macs, greatly facilitated by Cameron Tod's very handy page.

o Let’s start on familiar Drupal grounds. Install the XHProf module. The module allows you to easily flick profiling on and off, without the need for defining an additional virtual host and accompanying special domain. The module also comes with some nice touches like selecting the verbosity of the XHProf output and not running XHProf on admin pages.

o The page ..../admin/reports/status/php on your Drupal site will tell you which PHP configuration file (php.ini file) your site has loaded. Edit that php.ini, adding these lines:

extension = xhprof.so
xhprof.output_dir = ...

On a Mac, typical candidates for filling out the above dots are /Users/USERNAME/Sites/xhprof/runs or /tmp/xhprof. Whatever you choose, make sure to create that directory or the xhprof module will spit the dummy. Keep in mind that the /tmp directory is automatically cleared upon startup, so you’ll have to create /tmp/xhprof again after a reboot.

o On https://github.com/cam8001/php-xhprof-mamp select the pre-compiled version of xhprof.so that corresponds to the PHP version you found above. Drop the xhprof.so in /Applications/MAMP/bin/php/php5.x.x/lib/php/extensions/no-debug-non-zts-200xxxxx/, replacing the x'es with your PHP version and date. If you've done this correctly then after restarting MAMP and refreshing the page .../admin/reports/status/php will display a xhprof section.

o In a Terminal window type these commands:

cd ~/Sites
curl http://pecl.php.net/get/xhprof > xhprof.tgz
tar -xzf xhprof.tgz
mv xhprof-* xhprof
mkdir xhprof/runs
# or: mkdir /tmp/xhprof

o Visit .../admin/config/development/xhprof and tick the “Enable” box. Accept the remaining defaults for now. You can revisit these later.

o Visit the home page, or any other page of your site. Scroll UP to see a link “XHProf output” at the very bottom of your browser window. Click that link and a list of the top 100 suspects should come up.

Happy profiling!

In a follow-up article we'll demonstrate how XHProf can help you discover where exactly server-side performance is lost on your site and a handy module that came out of that.

File under:  Planet Drupal
Categories: Drupal

Simple FB Publish

New Drupal Modules - 28 June 2014 - 11:10pm

This module depends on Simple_FB_Connect (v1.13 or higher) and also requires Rules Module.

This module adds a Rules Action that would allow posting to user's Facebook Wall.

Categories: Drupal
Syndicate content


Google+
about seo