Import And Export Menus With Menu Import Module In Drupal 7

Menu Import allows site builders to import and export menu structures using a simple JSON style notation. The module helps site builders to create, test and deploy menu structures without having to re-enter in menu items over and over again – you will save a lot of time using this module.

Here is an example, if you were to import the text below, you’ll end up with a menu structure that represents the order and depth of the text.

Handling View Modes and Regions with Display Suite in Drupal 7

In the previous tutorial, we jumped right into using Display Suite. We selected a layout and configured fields for the Teaser and "Full content" view mode. In this tutorial, we’ll look at how to create a custom view mode, use view modes within the Views module, custom wrappers and custom CSS classes.

What is a view mode? View modes allow you to display content types in multiple ways. For example, the Article content type comes with a Teaser and "Full content" view mode. When you go to an article content page (node/1) you’ll be shown the "Full content" view mode of the article. Whereas if you view the article node on the homepage, you'll be shown the Teaser view mode of the article.

Configuring Layouts with Display Suite in Drupal 7

Display Suite allows site builders to customise how content is displayed. When I say content, I mean nodes, users and taxonomy pages as a basic example. At a lower level, you are modifying the display of an entity. All major pieces of content like nodes, users and taxonomy terms are simply entities. In Drupal 7, a lot of contributed modules implement their own entities. For example, Drupal CommerceField collection or Bean module just to name a few. Display Suite makes it very easy to customise the layout of any entity using a drag and drop interface without writing custom code or overriding template files.

Getting Started with JSON in Drupal 7

How can you transfer data between websites? There are many options and modules for Drupal out there. You can use the Services, RESTful Web Services or Views Datasource module. However, using those modules can sometimes be a bit overkill. If all you want to do is expose some data via JSON so that it's accessible for other websites, then it’s easier to create a custom menu item and just return the exposed data as JSON from a menu callback.

Handling Addresses and Locations in Drupal 7

In the good old Drupal 6 days, when you had to store an address and have that address converted into a latitude and longitude you would use the Location module. If you wanted to display a Google Map on your website, you would use the Gmap Module. In Drupal 7 the landscape has changed and now you have a lot options than just using the Location module.

Create Tooltips with Tipsy Module

Just recently for one of my websites I did a bit of research to see how easy it’ll be to add keyword tooltips. What I want is when a user hovers over a keyword within a piece of content a nicely styled tooltip appears. There are a few modules on drupal.org that integrate with jQuery popup/tooltip plugins, however, I ended up choosing the Tipsy module. As the name suggests, the Tipsy module uses a jQuery plugin called Tipsy and the jQuery plugin creates Facebook-style tooltips.

Handling Date and Time in Drupal 7

Over the years of maintaining Drupal websites I noticed that a lot of developers – and themers – hard code date and time formats. I know this may sound like a rant, but I would like to demonstrate an easier and cleaner way of creating and managing date and time formats.

Message Module API

The Message module is a general logging utility tool which you can use to log any type of activity on a Drupal website. I’ve already written about how you can use Message module with Rules. If you’ve never used this module I would recommend that you read "Log Site Activity with Message and Rules" first, so you can get a good introduction on how to use Message module.

In this article we’ll look at creating messages programmatically via Entity’s entity_metadata_wrapper() function. Finally we’ll look at how to load and display a message log. This is useful if you need to manually add a message to a template file.