views

Creating Custom Lists Using Nodequeue

The Nodequeue module is an incredibly useful module that allows you select individual nodes and place them in a list in whatever order you like. This lesson shows you how to create a new nodequeue, add nodes to the queue, arrange the queue and then add the queue to a view.

Note: Click the 'full screen' icon (to the left of the volume control) in order to watch online at full 1280x720 resolution.Note: Click the 'full screen' icon (to the left of the volume control) in order to watch online at full 1280x720 resolution.

Bookmark and Share Bookmark or Share Post

Image Gallery Enhancements

This lesson shows you how to enhance the image gallery created in the previous lesson using Thickbox, Media RSS and Views Slideshow.

The premium version of this lesson is encoded at the full 1024x768 resolution as originally recorded.

Bookmark and Share Bookmark or Share Post

Create An Image Gallery With CCK, Views And ImageCache

This lesson shows how to create an image gallery using CCK with ImageField, Views and ImageCache. CCK is used to create a new "image" content type that contains an upload field for images courtesy of ImageField. ImageCache is used to crop and resize the uploaded images. Views is used to display gallery page and an accompanying RSS Feed.

The premium version of this lesson is encoded at the full 1024x768 resolution as originally recorded.

 

Bookmark and Share Bookmark or Share Post

The Power Of Drupal Views

 When people ask me why I would ever use Drupal to build a website instead of other platforms like WordPress or Movable Type I typically have one answer, "CCK and Views." That could be interpreted as two answers but since the modules go hand in hand I'll call it one. I've written about the basics of CCK before so I recommend that you check out that post if you're interested in understanding CCK better. This post is about the Views module.

Views is a module that offers Drupal site developers (you I presume)  great flexibility of choices for displaying content. Views provides this flexibility by offering up a graphical user interface (pictured below) that allows you to query the Drupal database for content and choose the format of the content display without having to write SQL queries. I've written plenty of SQL queries in the past for business purposes and if I never write another one I won't be disappointed. If you want a much closer look at the interface I'm speaking of feel free to check out one of my videos that shows you how to do something practical with views.

Views Interface

Views Interface (Drupal 6)

Three Basic Types of Views

There are three basic types of views available in the base module. You can display content as a page, block, or RSS feed. When I say "content" I mean entire Drupal nodes or individual fields. For example, the page at http://learnbythedrop.com/cckandviews is a "view" that lists x number of nodes. When you list the node you get the Title + Body, plus links to comments and any other fields that would display when you are viewing a node. If you choose to display fields instead of nodes, then you can pick and choose individual fields from your nodes to display. For example,. the page at http://learnbythedrop.com/archives displays the Title (linked to the node), (Number of) Views, (Number of) Comments and (Number of) Votes fields.

The one thing that the views mentioned in this paragraph have in common is the fact that they are "page" views. Page views differ from other views because you assign a path (like http://learnbythedrop.com/archives) that displays the view as a page on your site. You can also create your list in a "block" view. When you choose block the content that you add to the view will be available on the block page (at admin/build/block) for configuration and placement just like any other block on the site.

You should put a little bit of thought in to what types of content you display in a block vs. a page. Blocks work well with lists of titles linked to nodes (see the "Recent Drops" and "Comments" blocks in the right sidebar), whereas a page might work best with full nodes or a collection of fields. Lucky for you that the views module has a very handy "live preview" feature that allows you view the results of your query while building your view.

The third type of standard view is the RSS feed view. This view outputs lists of nodes as an RSS feed that people can subscribe to in a feed reader such as Google Reader. If you have set up a page view that has the same content as the RSS feed you have the option to associate the RSS feed with that page and a small orange RSS Icon will appear on the page. See the bottom of the page at http://learnbythedrop.com/gallery for an example of how this looks.
 

Style Options

Drupal views also have several standard "style" options which differ depending on the type of view you choose. RSS, for example, is really a style option for your view. But if you choose to set up a page or a block view you have different options as to how the final display will appear. Some examples of style options are unformatted, list, grid and table. If you're creating a page full of nodes then you'll likely choose "unformatted" as your style. But if you're choosing a page with individual fields (like http://learnbythedrop.com/archives) then a "table" style might work best. For blocks that have lists of titles linked to nodes I typically choose the "list" style. Once again, the live preview option is your friend when making these types of decisions.

The "grid" style is an interesting choice if you're displaying just a couple of fields and want to repeat the content across and down the page. I've implemented this style on my view at http://iheartmets.com/metstweets, which shows a grid of recent tweets about the New York Mets.

Bookmark and Share Bookmark or Share Post

Using Views To Create A Block

This lesson shows how to use the Views module to create a block that contains a list of node titles that link to their respective nodes.

Bookmark and Share Bookmark or Share Post

Creating An RSS Feed Using Views

This tutorial shows how to create an RSS feed from an existing view. See Creating A Page View From A Taxonomy to see how I created the initial page view.

Bookmark and Share Bookmark or Share Post

Creating A Page View From A Taxonomy

This video shows the user how to use the views module in Drupal 6 to create a page that list nodes with a certain taxonomy term. For the screencast I created a view that lists all of the nodes tagged with cck or views at http://www.learnbythedrop.com/cckandviews.

Bookmark and Share Bookmark or Share Post

Introduction To Views

This video gives you a very basic introduction to the views module in Drupal 6.

Bookmark and Share Bookmark or Share Post

Significant Changes To Views For Drupal 6

There have been significant changes to the interface for creating views in Drupal 6. This site is based on Drupal 6 and I've had the opportunity to work with the new interface for the first time.

The new process can be a bit confusing so I recommend that you experiment with some sample views before jumping in. Once you get to know the new functionality I think you will find that it is a very nice improvement over previous versions of Drupal.

Bookmark and Share Bookmark or Share Post
Syndicate content