To revert all features ..
drush fra -y drush cc allTo revert a specific feature..
drush fr -y feature drush cc allIf a feature has been overridden, it can be reverted. This means that the version in the database is destroyed and the version defined in code, in your feature, is used.
If you're deploying a feature to one of you servers you would ..
git pull drush fra -y drush cc allTo update your feature ..
drush fu -y feature drush cc allUpdating an overridden feature will ensure that the version of the feature defined in code is made to match the version stored in the database.
A feature is overridden when a user uses the UI to make configuration changes. These changes are stored in the database, and override what is stored in code.
Tags: featuredrushdrupalplanet TweetOne of the popular functionalities we build at Propeople Drupal Agency are slideshows. Thanks to views_slideshow module it’s a very easy task to implement. Sometimes slideshows contain embedded YouTube videos. And thanks to the great Media module, it is not a very hard task to do either.
The only problem we face is when the user clicks play – the slideshow still switches to the next slide. This article addresses this problem.
We have found a nice example of reacting on YouTube player play / pause.
In order to use this example we will need to override media-youtube-video template as we will need to change the output.
In order to accomplish this we can create our own template and add it to suggestions in case this field is displayed in a view with slideshow.
<?php
/**
* Implements hook_theme().
*/
function mymodule_theme() {
return array(
'mymodule_media_youtube_video' => array(
'variables' => array('uri' => NULL, 'options' => array()),
'template' => 'mymodule-media-youtube-video',
),
);
}
/**
* Preprocess function for template media-youtube-video.tpl.php
*/
function mymodule_preprocess_media_youtube_video(&$variables) {
if (!_mymodule_search_backtrace('template_preprocess_views_view_field')) {
return;
}
$views_id = drupal_static('mymodule_preprocess_views_view_field');
if (empty($views_id)) {
return;
}
drupal_add_js('http://www.youtube.com/player_api');
drupal_add_js(drupal_get_path('module', 'mymodule') . '/mymodule.js');
$variables['theme_hook_suggestions'] = array('mymodule_media_youtube_video');
$variables['iframe_id'] = 'media-youtube-' . $variables['id'];
$variables['views_id'] = $views_id;
}
?>
The mymodule_preprocess_media_youtube_video() function does some tricks:
1. It checks whether rendering of media file is done inside the view. For this we check the backtrace for template_preprocess_views_view_field function. This is pretty hacky but I haven't found a nicer way to check. It is needed so we do not modify output if for example media file displayed in the node.
2. It loads $views_id from static variable. This is another pretty ugly hack, but it is needed for passing a variable to javascript (so we know what slideshow to pause / start). Also when we prepare that variable we check if a view actually uses slideshow style.
I would love to hear if you know a better workaround for these two hacks. Write in the comment form below or on our social profiles: Twitter, Facebook.
The function where we prepare the view id:
<?php
/**
* Preprocess function for views-view-field.tpl.php.
*
* Statically cache view information to pass to mymodule.js so we know what slideshow to pause.
*/
function mymodule_preprocess_views_view_field(&$variables) {
$views_slideshow_id = &drupal_static(__FUNCTION__);
$views_slideshow_id = '';
$view = $variables['view'];
if ($view->style_plugin->plugin_name == 'slideshow') {
$views_slideshow_id = $view->name . '-' . $view->current_display;
}
}
?>
Now the template file:
<div class="<?php print $classes; ?> media-youtube-<?php print $id; ?>">
<iframe id="<?php print $iframe_id; ?>"
class="media-youtube-player media-youtube-mymodule" <?php print $api_id_attribute; ?>
width="<?php print $width; ?>"
height="<?php print $height; ?>"
title="<?php print $title; ?>"
src="<?php print $url; ?>"
frameborder="0"
allowfullscreen
data-iframe_id='<?php print $iframe_id; ?>'
data-video_id='<?php print $video_id; ?>'
data-views_id='<?php print $views_id; ?>'
>
<?php print $alternative_content; ?></iframe>
</div>
As you can see, we are passing iframe_id, video_id and views_id as attributes of the iframe so javascript can use them.
And the last piece is the javascript itself:
<javascript>
(function ($) {
Drupal.behaviors.mymodule = {
attach: function (context) {
$('.media-youtube-mymodule').once('mymodule').load(function() {
iframe_id = $(this).data('iframe_id');
video_id = $(this).data('video_id');
views_id = $(this).data('views_id');
// Example of interacting with YouTube API's
//@link http://jsfiddle.net/masiha/4mEDR/
var mymodule_player = new YT.Player(iframe_id, {
videoId: video_id,
events: {
'onStateChange': function (event) {
if (event.data == YT.PlayerState.PLAYING) {
Drupal.viewsSlideshow.action({
"action": 'pause',
"slideshowID": views_id,
"force": true
});
}
else if (event.data == YT.PlayerState.PAUSED) {
Drupal.viewsSlideshow.action({
"action": 'play',
"slideshowID": views_id,
"force": true
});
}
}
}
});
});
}
};
})(jQuery);
</javascript>
The full code of this drupal module can be downloaded here.
Now, after enabling this module, if you build a slideshow with media youtube files it should apply this functionality automatically.
Enjoy.
Language English Tags: DrupalDevelopmentTutorialsCheck this option to include this post in Planet Drupal aggregator: planetI created a bare-bones content filter to add musical notation to Drupal content, using the VexFlow / VexTab music engraving library. Here's a little sample, also showing my fork of the original library to handle basic Arabic musical notation (quarter tones and special scales):
tabstave notation=true tablature=false clef=treble key=Rast notes C/4 D/4 E%@/4 F/4 | G/4 A/4 B%@/4 C/5Feel free to fiddle with the music snippet above.
In this lesson we're going to talk about taxonomy. In my experience it's another one of those things in Drupal that uses unfortunate terminology and ends up confusing new users. But the truth is, taxonomy is pretty simple to get your head around and will be a huge help in your site building efforts.
The Lowdown on this TutorialWe're going to break this topic down by first explaining the concepts. Next we'll take a brief tour of where Drupal keeps all the knobs and switches for managing taxonomy and then we'll wrap it up by discussing some very useful modules that extend the built-in functionality of the Taxonomy module.
If you've been keeping up with this tutorial series, you'll know it uses my free installation profile, Foundation, for the examples. Using Foundation along with the lessons can save some time in getting up to speed on this topic. It includes several pre-configured modules and views related to the topic of taxonomy that serve as good examples of how it can help with your site building.
Taxonomy DefinedLet's begin by defining taxonomy. You may remember it from your high school biology class as a systematic way of categorizing things. In biology, the classifications involve plants and animals, but in Drupal the categories are for your content.
If you're coming from WordPress, this system is very similar to the Categories you'll find in that CMS. In Drupal, however, it's a little more complex - big surprise, right? That's OK. Like I said, it's not that bad.
To really understand Drupal's taxonomy or classification system, we have to get a handle on both vocabularies and terms. Vocabularies are really just categories. That's all they are. Terms are simply the items that go inside a vocabulary. Let's look a little deeper at terms and vocabularies using an example.
A Hypothetical VocabularyBy default, Drupal comes with one vocabulary defined - Tags. It's a generic, default way to start classifying your content. But let's say we have a site that provides information about the nutritional content of various foods. We'll probably want to create a new vocabulary (aka category) that we'll call Foods.
Under that vocabulary we'll start adding some terms to break our content down into more specific classifications - terms like Dairy, Grains, Poultry, Vegetables and Fruits. As you might guess, these will end up being not only terms themselves, but also the headings for sub-categories as we continue drilling down to more specific terms. For example, under Fruits we might have Apples, Bananas, etc. You can see that it won't take long before we have a very extensive hierarchy with hundreds, or even thousands, of terms.
Of course the point of all this categorization is to make it easier to sort our content and expose how each node is related to the others. If you think back to the previous lessons on Views, you'll start seeing how these two modules - Taxonomy and Views - work hand-in-glove to provide a way of creating and displaying content relationships in a relatively simple way.
How to Use TaxonomyLet's kick this section off by looking at where we create and manage our vocabularies and terms. In Drupal 7, under Structure > Taxonomy you'll find a screen like the one below.
You'll see that in this screenshot from Foundation, we have two vocabularies, the default Tags, which I've chosen to use as the blog categories, and a second titled, Utility tags. This second vocabulary/category is used to mark content as special in some way - for example, to be featured on the home page.
I won't go through the steps of creating vocabularies or terms because it's very simple and I'm certain you can handle that without much trouble. But what we are going to look at is how we can make our new vocabularies available for use when creating content. You see, when you create a new vocabulary, it isn't automatically available on your Add content form. We have to add it manually.
To do this, we'll need to add a field to the content types where we want to be able to use the vocabulary. If you're using Foundation, head to Structure > Content Types and then select Manage fields under the Article content type. You'll see something similar to the image below.
Note the big red arrow. What you see is that I've added a field to my content type. It's a term reference and it associates the vocabulary Utility tags with the content type. In this case it allows me to tag an article as one that should be added to the home page (via a view).
But if we return to the example of a Foods vocabulary, this is where we could add it as well. We would simply add a new field and under field type, select Term reference and then set the desired widget (select list, checkboxes, etc.). After we click save, we'll be prompted for the vocabulary name and some default settings for the field.
After we've done this, we'll be able to tag our content with the terms we've defined when we're creating or editing the page. It's pretty simple, but if you want your users to be able to see the vocabulary terms on the page (so they might click them to view related content), we're not quite finished.
Go back to Structure > Content Types and then select Manage display under the Article content type. You'll see something similar to the image below.
You'll notice that in this case we have our Utility tags hidden from our site's visitors. But in the case of our hypothetical Foods vocabulary, we'd want to make sure it was displaying so that our site's visitors could use it to find and perhaps sort related content.
If this was what we wanted to do, I would also recommend enabling the Taxonomy term view (included by default with Views) and customizing the display of the pages that site visitors will see when they click on a taxonomy term. It would be in this view where you might expose a dropdown to your users that would let them easily sort through the content associated with the various terms you've defined.
Related ModulesThat wasn't so bad, was it? It won't be long before you'll want to do all sorts of things with taxonomy and below are a few modules that will help.
Taxonomy MenuThis module will allow you to turn your vocabularies into menus. In my experience, the module works great so long as you don't try to disable any menu items. I've always had disabled items get re-added after cron runs, but otherwise no problems.
TagadelicYou know those tag clouds you've seen on some sites? This module is one way you can do that with Drupal.
Taxonomy BreadcrumbIn the example we used in this tutorial, we saw how quickly you can create a deep vocabulary structure. The Taxonomy Breadcrumb module is a useful way of helping your users keep track of where they are.
The Rest...Finally I'll leave you with the full list of taxonomy related modules - only 372 of them for you to sort through! Gotta love Drupal, huh?
That's it for this lesson. We're a bit more than a fifth of the way through this series. Stay up to date via the series RSS feed or by subscribing to email updates for the blog. If you'd like to comment on anything in this lesson, you can do so on this discussion thread.
The way that a DrupalCon comes together is similar to how releases of Drupal are produced by the community. Passionate experts in their subject matter areas volunteer tirelessly to make each DrupalCon grow and exceed the expectations of the past.
Personal blog tags: drupalconcommunityThis series outlines our project process through the lens of our development of the new 4SiteStudios.com. In this post, we will discuss our process for developing an user experience for our new website.
As we have been planning the new 4SiteStudios.com over the past few weeks, we have followed our typical project process. After I developed the content plan for the new website, I dove right into developing wireframes, taking into consideration things like messaging hierarchy, information architecture, content models, modern design trends, and the lot.
In my mind, our new website is a framework. We are putting into place a foundation to build a great digital experience that can be a showcase to our clients of how we work and how awesome we are at what we do. The site will be a conversion machine. But, it will take time and learning from user behavior to get there. So, we need to start simple.
My goal is to present visitors, with as little content as possible, the following in order of priority:
The work we have done (As we say in the agency world: “The work sells itself.”)
The spectrum of services we offer
Who we are as a company
Our thought leadership around creative content and user engagement
If you take a look at the user personas in our content strategy, you will see that our target audiences are looking to make a quick decision about hiring us. They will visit our website to look at our portfolio, get a sense of the services we offer, and maybe read some blog posts or other resources. We need to give the user what they are looking for quickly, with minimal barrier to entry.
Wireframing our New WebsiteThis was a collaborative process...as much as we could make it. I brainstormed approaches and ideas with John and Alexis almost daily. I would have informal powwows with them to get their thoughts on how to structure content regions and get feedback on the wireframes as I was designing them. We whiteboarded, drew out ideas on napkins,, and debated a lot. In the end, we made Jeff Gothelf proud - we were lean.
The direction I took with the homepage was a stacked pane approach, as seen with many modern websites. It made sense for what we wanted to accomplish - create very distinct regions, each communicating a key message.
Since we don’t have, nor can we produce, a lot of content for the new website, I made each top-level navigation item a distinct landing page, and each subpage under it a defined region within the landing page. I then used conversational headers and intro text to tie these regions together into a narrative. With our new brand, we want to be more conversational with our content, so this approach makes sense for us.
I am a big fan of repeating patterns within websites so users can intuitively know how to navigate through content. Aside from our main navigation, Sliders are used consistently throughout the website to allow users to scroll through pages where there is content they will want to consume in isolation, such as a service descriptions. Exposed dropdown filters are used to allow users to easily find content within large groupings, like our portfolio and “Insights” page. Galleries will be displayed using a masonry layout, and listings of content in a grid layout.
If you read my last post on the content strategy for the website, you know that one of our major goals is to increase leads generated through the website. You will see webforms consistently incorporated throughout subpages on the new website where we describe what we do and products we have developed. That black circle that appears in the upper right-hand corner of the website will follow people as they scroll down a page. We need to make it easy for you to contact us about your next project, right?
The user experience is not complex. We want to keep the new website simple and clean; prioritize visual communication over written content (with the exception of our thought leadership content); and build a conversion machine. We will be improving the website over time, testing out landing pages and improving the design and copy based on user need, so we did not want to over-engineer anything.
The Review ProcessNow, I know I make the process of creating the user experience sound like it was easy, but it was kind of painful. Creating a content strategy isn’t hard - much of it is conceptual and you don’t know what you get until you start building it. People respond more to visual queues, so the amount of feedback on a project increases exponentially the more people get to see what a website is going to look like.
Although wireframes are meant to communicate content structure and page layout, people easily get hung up on the details.
“Can we change that word to {blank}?”
“Are we going to have a slideshow on the homepage?”
“It would be REALLY COOL if {blank} did {blank}?”
You have probably heard at least one of those questions before...
It took work to get our team’s consensus on the wireframes. The key was to make people feel as though their feedback was important,, but allow them to give “just enough” feedback to gather the requirements you need and build buy-in amongst your stakeholders. Perfection is the enemy of good.
Setting parameters around what I needed feedback on and how long people had to provide their feedback was extremely helpful. Changes and feedback at the end of the process were minimal because I spoke with people throughout the process, allowing them to give feedback along the way.
It is also important to stress to people that project planning is an ongoing process. Just because you reach a point where you stop collecting feedback on wireframes doesn’t mean changes cannot be made at a later time. Planning documents should be living documents that are updated throughout the development process as requirements change.
Things I would have done differentlyLooking back on the process, I feel like I spent too much time on the wireframes. Part of the challenge with wireframes, as with design mockups, is that people cannot easily visualize how things will look and behave in the browser. Spending hours making really nice, static wireframes is counterproductive. It won’t allow people to interact with the concept and get a true sense of the functionality. The feedback you receive will be incomplete because the experience will be incomplete in the mind of the reviewer.
There is an argument to be made for high-fidelity wireframes. Interactive wireframes and prototypes communicate function well, but not form. There needs to be a balance. The compromise for me is “mid-fidelity wireframes” - wireframes that include just enough design aesthetic so the viewer gets a sense of the design page layout and form, but does not dictate the design direction.
We have already begun to refine our process to incorporate interactive wireframes and/or prototyping. There are a few ways to approach this, and we are planning to either create interactive wireframes within Mockflow, our preferred wireframing tool, or go right into prototyping using Drupal, depending on the project.
Take a look at the wireframes for our new website below and let us know what you think.
New 4SiteStudios.com Wireframes from 4sitestudiosThis is little introduction into one of the simpler, and more user-friendly ways of controlling spam in Drupal (as opposed to other also-helpful methods, like Mollom, CAPTCHA, etc.).
The Honeypot Method
Honeypot is aptly named because, just like Pooh bear is drawn towards honey jars, spam bots are drawn towards form fields—especially form fields they think will give them the ability to link back to their own websites. So, the Honeypot method basically inserts a hidden form field to Drupal (or other) forms with a field name like 'homepage' (you can set it to whatever you want). End users don't see the field, so they don't fill it out. But spam bots (usually using prewritten scripts) do see the field (usually), and add something to it. The Honeypot module detects this and blocks the form submission if there's something in the field.
Additionally, the Honeypot module adds in a timestamp-based deterrent. Usually, forms take at least a few seconds to fill out when a human is entering data into them—especially surveys, user registration forms, etc. Spam bots try to fill out as many forms as they can in as little time as possible, so they will often fill out a form within a couple seconds at most. The Honeypot module requires at least 5 seconds to pass (by default - you can adjust this too!) before a form can be submitted.
The Honeypot + timestamp form protection method is a very good defense against spam bots, but not so good against actual humans who fill out forms for spammers although there are now some ways you can configure the module to deter 'real' spammers; see honeypot.api.php). If you start having serious spam problems, you might need to add in Mollom or another more intelligent spam prevention service to the mix. The greatest advantage of the Honeypot method is that the user is given no extra obstacles to completing a form. In my opinion, it's the most user-friendly way of preventing spam, even if it's not the most effective in every situation.
Other Niceties
You can also bypass the Honeypot protection for certain user roles—say, for instance, site administrators, who just might be able to fill out a form in less than 5 seconds—and you can set which forms on which Honeypot protection will be enabled. You can also tell Honeypot to protect all forms on the site. Finally, you can use honeypot protection in any of your own forms by simply including a little code snippet inside your modules hook_form_alter.
By now everyone hopefully made it safely home from DrupalCon (if you're still there, it ended more than two weeks ago so you might want to head home), and while the dust settles we wanted to say thanks to all who helped make DrupalCon Portland a success, and also share some highlights from Lullabot.
The Lullabot PartyThis is about Views Contextual Filters.
No don't run away yet…. give me a sec… please.
I am well aware that even seasoned site builders fear to tread into that hidden-by-default upper right-hand corner of the Views UI configuration page labelled "Advanced". Most of us have opened it once, seen the heading "Contextual Filters" and gone "Mwaaah… what's that cr@p and what good is it to me?"
Well quite a lot of good, actually. If you can just hang in there, I'll get straight to the point.
You need contextual filters instead of, or in addition to, normal filters when:
1) you want to pass arguments to a View that has no exposed filter UI or that needs its UI bypassed initially, e.g. from links elsewhere on the same or another site, or in an email or newsletter
2) you want to do funky stuff with Panels and the like, which we won't discuss here
3) you want to pass a filter argument to many different Views at once, residing as pages and in blocks, all from a single UI widget, which you can place as a little block anywhere on your site -- the picked once, operates site-wide (POOS) filter principle.
That last quality facilitates UX enhancements many continue to ask for and for good reason.
Here's a few use-cases:
o a visitors lands anywhere on a site, be it one for real estate, events or travel and enters state, city or postcode of interest; instantly all relevant pages on the site filter on the region entered, without the visitor having to re-enter their selection again, unless they wish to change it
o a user visits an online gift ship, enters maximum spend and... *poofff*... only sees applicable merchandise on any of the pages they visit
o same for date ranges, music genres... any taxonomy terms, any field occurring in more than one View on your site
So how do you give your plain contextual filters the far-ranging wings of point 3) ? Views Global Filter, that's how. Try it.
And if after that you still dislike contextual filters, write to us -- you'd be the first to complain.
* * *
Note re point 1) above: if you want to contextually pass to a View filter ranges, e.g. 50--150, rather than single values, check out Views Contextual Range Filter
File under: Planet DrupalLast Wednesday, I felt an urge to carefully write out a list of all the possible characteristics that would make communications technology genuinely free. I felt this was important for a number of reasons: for example, to follow up on my earlier claim that free software does not always provide free communications, it is necessary to be able to measure the shortcomings against a perfect (although possibly unachievable) benchmark.
Then something happened
Just hours after my blog was live, The Guardian, a leading British newspaper (and contributor to open source) started publishing explosive allegations about the extent of US Government monitoring of communications. They kicked off a dramatic four days of coverage of this topic with the story that one of America's largest phone companies, Verizon, is secretly passing details of all customer phone calls and approximate locations (metadata) to the NSA.
I've published further blog entries about this subject in the meantime. One thing I want to make clear: real friends tell each other the truth. There is no need to flatter America with gratitude for inventing the Internet when discussing these fundamental privacy failings. Anybody who has tried to generalise any comments about the NSA scandal as `anti-American' is themselves failing to respect America's own principles of free speech. A doctor doesn't make up fairy tales for a patient diagnosed with cancer, he puts the facts on the table as that is the first step in making progress.
The winds of changeActivity on all my free communications web sites, especially Lumicall and OpenTelecoms.org has doubled. Google Play reports that the rate of Lumicall installations have also doubled - hopefully it is getting closer to the point where Metcalfe's Law kicks in and everybody will have federated SIP on their phone.
What nextOne thing is clear: this situation provides a huge opportunity for anybody promoting free software, not just for communications. As I mentioned, web sites on the subject of free and private communications are attracting significant interest and I hope this rubs off on other projects. While I have contended that free software does not always provide free communications, there is a compelling argument for the case that you can't have free communications without having genuinely free software.
Some of the developments that are coming up in the very near future:
An upcoming release of DruCall, initially packaged for Debian and leveraging the libraries API packaging scheme, is going to make it much, much easier for the vast majority of web sites to offer a secure calling facility, without any third-party browser plugins required. Other CMS vendors such as xWiki are also working on WebRTC support.
DebConf13 is aiming to feature a half-day track on Free real-time communications with a focus on the way free operating systems, particularly Debian (and it's derivatives like Ubuntu) are fundamental to rolling out an alternative to the status quo.
Federated VoIP is also a confirmed feature of the upcoming Fedora 19 release and will eventually work it's way into EPEL. This is another great way for people who work in an RPM environment to start getting more active deploying SIP as a standard service in their environment.
The real-time communication (RTC) quick-start guide is currently being updated and will include a convenient web-checker to help people test their federated connectivity.
Can you help? Not sure where to begin?Come and join us on the Free RTC discussion list that has been sponsored by the FSF Europe or join the discussion list of one of your favourite free RTC applications.
Drupal has become a hugely popular framework for building big websites and is becoming more and more widely used in government and public sector. The likelihood of these organisations wanting to offer SSO to their users is pretty big also.
The Drupal Lightweight Directory Access Protocol or “LDAP” module allows, for organisations that hold their user data in an Active Directory installation, their users to login to the Drupal site using those credentials.
The setup of an Active Directory instance is a little outside the scope of this blogpost but there is a fantastic knowledge base article by Rackspace that guides you through the setup perfectly (http://www.rackspace.com/knowledge_center/article/installing-active-dire...).
The configuration screen (found at admin/config/people/ldap) is split into a number of tabs. We will firstly be concerned with “Server”, this tab allows us to define our connection credentials to our Active Directory instance. Multiple server configurations can exist and we can even define multiple server configurations for a single physical LDAP server for things like, alternate base DN’s (Distinguished names) or alternate service accounts with different privileges.
Connection Settings
The connection settings screen is pretty self explanatory, fill it out with your server credentials, I would normally leave ‘Enabled’ un-ticked until you verify that everything is working correctly.
After the server connection details are entered, this is where things get a little more complicated. The following fieldsets, Binding Method, LDAP User to Drupal User Relationships and LDAP Group Configuration all ask for DN’s or attributes belonging to LDAP objects. I found the best way to navigate around the LDAP server was by using a third party piece of software called ‘Apache Directory Studio’. It is available free on OSX, Windows and Linux! Here are a few common terminologies used in LDAP.
Binding Methods
The LDAP.module suggest using a Service account to allow for searches and to determine user objects and their groups memberships. Within our LDAP instance we created a service account ‘Code Enigma’, we can use the Apache Directory Studio to drill down to that user object and determine its DN.
From the screenshot above we can see that our Code Enigma user has a Distinguished name of
CN=Code Enigma,CN=Users,DC=windows,DC=codeenigma,DC=com
We use this DN to populate the following section of the form, along with its password to allow it to authenticate to the Active Directory server.
Our base DN for users, groups and other entities can be found in the same way. Our Base DN for our users for example is CN=Users,DC=windows,DC=codeenigma,DC=com which exists one level above our Code Enigma user.
LDAP Group Configuration
Name of Group Object Class
We find the name of the group object class in the same way, we drill down the LDAP tree and find the groups under CN=BuiltIn. In this instance our group object class is named ‘group’.
Attribute in User Entry Containing Groups
This value is taken from the attribute that lists a users group memberships. In our instance this is memberOf, from the screenshot below you can see that the user ‘mark’ is a member of both Administrators and Users.
Once you have your connection setup and working, we can move onto setting up how the site will interact with the LDAP server.
LDAP to OG group Configuration
The Drupal LDAP module comes bundled with “LDAP Authorization - OG (Organic Groups)” module that allows us to automatically join users to Drupal groups dependant on their LDAP groups.
The workflow for achieving this is to inspect your LDAP server and make note of the groups you want users to automatically join as an Organic Group. The LDAP module does not provision these Organic Groups for us, therefore we need to create the Organic Groups and map them from LDAP to Drupal.
Using ‘Apache Directory Studio’ we can find the DN to our individual groups, such as for Administrators.
CN=Administrators,CN=Builtin,DC=windows,DC=codeenigma,DC=com
The mapping of LDAP to OG group is in the format, DN|Organic Group Title:Member Type. Using the screenshot above as an example, I created an Organic Group called 'Administrators' and used the following code in the "Mapping of LDAP to OG group (one per line)" textarea.
CN=Administrators,CN=Builtin,DC=windows,DC=codeenigma,DC=com|node:Administrators:member
The help text here is great and explains things very well, note that once you save, the module appears to append a shorthand version of your definition in the format (raw: node:1:2).
This format can be helpful if your Organic Group's title contain a : in the title, you can then use the alternative definition format DN|Organic Group ID:Member Type.
LDAP to drupal role Configuration
The role configuration is much the same as the Organic Groups settings. We simply discover what our Role DN's are in LDAP and map them to Drupal roles using the form provided.
The above configuration will map an Administrators group in Active Directory to an Administrtors role in our drupal install. The common name (CN) of the group and the role name do not have to match here, we are simply mapping one onto the other.
The "Create drupal roles if they do not exist" is an important setting that is hidden under "Part III. Even More Settings.", without this ticked any roles will not be created and only existing roles will be mapped. This may be the setup that you wish but it is without doubt a gotcha to look out for.
I hope this helps get your site up and running with Drupal, Active Directory and LDAP!
Related Service Areas: ConsultancyDevelopmentSupportTeaser: Mark Davies explains how to configure Microsoft Active Directory and Drupal's LDAP module for Enterprise integration with DrupalCategories: DevelopmentDrupal PlanetSupportPrimary Category: DevelopmentTags: ldapactive directoryssomicrosoftintegration
Having a Drupal 8 site under development with a customer aware of the risk of loosing data I took the risk of fixing a broken Drupal 8 site. Today I did an code update and got the following welcome screen on http://drupal.dev
If you have just changed code (for example deployed a new module or moved an existing one) read http://drupal.org/documentation/rebuildSymfony\Component\DependencyInjection\Exception\ServiceNotFoundException: You have requested a non-existent service "url_generator". in ...
The development site was synchronised using the usual drush commands
drush rsync @drupal.tst:%files @drupal.dev:%filesSo where's the test site standing?
$git log -n 1So we are 12 days behind.
Dev siteLet's check what happened and can we fix it?
$ git pullWow ... 12 days 235 commits ... that's too much. We know it worked once so let's start with that good version. First we tell git we want to find code where it went wrong and which version was right.
$ git bisect startNow git takes the middle between HEAD and the good version. Checking the front page now shows it's
$ git bisect badHmmm ... I made a mistake. That version is probably good enough.
$ git bisect good 3fdf6a1c139fd2a36ff8bf12f1b29f31bced8973So this continues for a while
583 git bisect badNow the site is working and no more bisect commits left.
$ git log -n 1Issue #2001310 by chx, effulgentsia, Berdir, YesCT: Disallow firing hooks during update.
So the current commit is OK. What happened with the next one?
$ git log origin/8.xIssue #1888424 by katbailey, steveoliver, twistor, beejeebus, effulgentsia: Change notice: Make Drupal's URL generation logic available to HttpKernel, and minimize code repetition/divergence.
Well that matches with the error. And the diff shows an interesting change on the core.services.yml
git checkout b21943922d94261dfa8de34995d206d5e8e9c3d7Now the puzzle is to solve this upgrade path.
Once you install Drupal 8 in a foreign language, you'll have Language and Interface translation modules enabled with the chosen language configured. Drupal 8 has more core modules handling language related features, yet less requirement for contributed modules to be installed for the most important tasks (on my last count, the 4 modules explained here cover functionality of 20+ modules from Drupal 7 and in much better ways).
Why have multiple modules when a multilingual site just needs all the features? Well, there are also foreign language (not multilingual) sites that we aim to support better and multilingual sites can be very different as well. Also, admittedly there are technological reasons to organize the modules by the features they provide.
In Drupal 8 (so far) multilingual is the only group of modules, so you'll find these modules under the other core modules in a neat group.
Accessibility
What modules are you using?
Patched modules along the way to make them accessible
Is this only applicable to government in Australia?
Collaborating with Canadian distribution
Had an independent audit by Vision Australia
Welcome to another Commerce Module Tuesday! Today we are looking at Commerce Product Add-on, maintained by Matt Robison who is the Vice President of Louisville Web Group. While I was at Drupalcon Portland, I was approached by two different individuals looking to do something that this modules makes very easy: Add a product as a checkbox on the add-to-cart form for another product.
Few weeks ago I was contacted by Gaby Becker with some issues for the GCM module I maintain.
I was happy to help, and was even more happy when she wrote a post in her blog describing the whole process.
Currently the implementation described actually uses a combination of GCM with the Push notification module, but the most important thing is that it works, and their Webgrrls Events application now got "push notification" capabilities, backed by standard Drupal modules.
My plans are to continue enhancing the GCM module capabilities, while releasing an Android SDK which will make it simpler for developers to integrate between Drupal and Android.
I hope this post will be useful for others, and thanks again Gaby for the detailed information.
Regards,
Shushu
If you want to have a native, single sign-on solution that is deeply integrated into Drupal, there is really just one option: Bakery. If you aren't aware of the Bakery module, it is what creates single sign-on between sites like drupal.org and groups.drupal.org, as well as most of the DrupalCon sites.
If you're wondering why the module is called Bakery it's because it deals with the cookies, of course. A read through the module's code will introduce you to such cookies as the OATMEAL cookie, the CHOCOLATECHIP cookie, and a variety of others. I won't get into what they all do, but suffice to say that it's an amusing read.
Bakery is ideal for Drupal sites because it is capable not only of providing SSO, but also of syncing Drupal profile fields and user avatars — and handling some de-duping of accounts — on top of providing account proliferation across multiple sites.
Author Michael CooperMichael has created products ranging from auto-malls to CRMs and lead-management systems. After encountering Drupal in 2007, he fell in love with its ability to help him deliver exactly what his customers needed, on an accelerated time frame. When he isn't coding, he's spending time with his daughter and wife or writing science fiction novels.
This series outlines our project process through the lens of our development of the new 4SiteStudios.com. In this post, we will discuss our process for developing a content strategy and user experience for our new website.
I tell the team here at 4Site that we are all strategists. We don’t just build websites for clients, we help them solve complex business challenges with creative content. We strongly believe that everything we design and/or build for a client should be informed by their content strategy.
We begin every client project with a Discovery and Planning phase. Our goal is to better understand our client’s business goals; communications and marketing strategy; and the needs, motivations, and behaviors of both internal and external stakeholders. Once we are equipped with that knowledge, we co-design solutions with our clients, weaving them into every step of the process.
It was an interesting exercise of going through this process with ourselves as the client. We just wrapped up the planning phase of our new website, and want to share how things went to give you a sense of how we could partner with you on your next project.
Content Strategy at 4SiteThe critical first piece of Discovery and Planning for us is developing a content strategy. While most organizations have some form of content strategy when we begin working with them, we are typically developing a strategy for a specific campaign or helping the organization to rethink the strategy they have in place.
Coming out of this process, we provide clients with a Content Plan, which includes our high-level recommendations for solving their business goals through this project; audience assessment and user personas; key messages and message hierarchy; information architecture; content type definitions and models; and page inventory. At the conclusion of this phase, our clients understand how content will be organized, presented, and used to communicate their key messages throughout their new website.
Defining Our Need for a New WebsiteWhen we sat down to begin work on the new 4Site Studios brand, we realized our current brand is a bit bipolar. We operate as two separate companies - we have a large list of clients we do event videography and video production for, and a long list of clients we develop Drupal websites for, but there is very little overlap between the two. Most of our video clients don’t know we do content strategy and build websites, and vice versa. Seeing this as a hinderance to the growth of the company and expansion of relationships with existing clients, we set our main goal for the rebrand to establish ourselves as a full-service digital creative agency, not just a production house or a Drupal shop.
As most digital agencies, we quickly decided to use our new website as the place to tell the story of who we are as an agency and showcase the full breadth of services we can offer to our clients. We felt we the new website should quickly, and consistently, communicate our new brand to existing and potential clients, and showcase our work in a way that speaks to our capabilities as an agency.
We were in a good place when we kicked off the planning process. I had just completed developing a marketing and communications plan for the agency, which defined our business goals and objectives for the next year or so. We skipped the upfront steps of setting project goals and objectives because we wanted the new website to drive our larger business goals, not arbitrary goals we set for our new website.
After the team reviewed and gained consensus on our marketing goals and objectives, I performed a content audit and dove into Google Analytics to find out how people were using the site, what content was most popular, how people were finding our content, etc. It was bad - people didn’t spend much time with our content; there were tons of broken links and errors; content was not optimized for SEO; and there were lots of contradictions in messaging across pages. To make matters worse, the site was architected in a way that didn’t allow us to easily make any improvements to the website markup or page layouts.
After I met with the team to present my findings, we determined it would be quicker to go back to the drawing board and create the new website from scratch versus trying to re-architect the existing CMS. We had an entirely new brand, new target audiences, and a more focused set of business goals; the original website was not designed with any of this in mind. By building an entirely new website, which we will be building on our own distribution of Drupal, we can focus our efforts on creative execution rather than bug fixes and platform optimization.
Developing the Content Strategy for 4SiteStudios.comI began our content strategy process by developing a set of user personas for the target audiences we defined in our communications and marketing plan. Through a combination of interviews with members of the team and colleagues in the industry; doing an analysis of our current and past customers; and a bit of social listening, I was able to get a good understanding of the needs of our potential clients, how they search for agency partners, and what motivates them to select a vendor.
I then mapped out brand pillars and statements to our audience needs to develop a messaging framework that would inform how we right content for key landing pages and informational content. The idea behind it is to always talk about topics and ourselves from the client perspective. “This is your need and and here is our solution to your need.” Make our content about the reader, not about us.
Once I had the key messaging in place, and a good sense of what content was most important to our personas, I proposed a sitemap and page inventory to the team. This was possibly the easiest review I ever had of a proposed information architecture for a website. Two small changes, and we were done.
Lastly, I extrapolated from our marketing plan, existing content, and the new information architecture the types of content we will need. Our content needs were fairly consistent with what we have on the new website, but the architecture needed to drastically change for easy of management and flexibility in presentation. I worked with our developer and site builder to define the key fields for each content type, and define relationships between them as necessary. I then developed recommendations for content portability using microcopy and SEO.
And, voila! Our content plan for the new website was done. Below is a copy if you would like to reach the entire thing.
4Site Studios New Website Content Plan from 4sitestudiosLast week’s SemTechBiz San Francisco was packed with insightful keynotes and sessions showing trends for semantic web technologies. The hot topics of the conference were Google’s, Yahoo’s and Wikidata’s Knowledge Graphs, as well as the adoption of schema.org, an initiative launched 2 years ago by the major search engines to standardize and promote structured data on the Web.