Quick Drupal 6 VIEWS overview

Views is a contributed module in Drupal. The Main purpose of this module is to provide a Graphical User Interface for fetching Node/contents from database. It has a query builder that generates the SQL query based upon your inputs. Download the views module and upload it in sites/all/modules folder. Now Navigate to the module section of Drupal admin. Enable the views and views UI modules. The views UI provides Graphic Screen in which user can enter the inputs and preview the results. After enabling the module navigate to admin/build/views to add a new view.

A View contains the below sections each can be configured

Filters: It allows the Node/content to be filtered according to the criteria. For instance if we want only a particular content type to be displayed say story or pages we can filter it here.

Sort: We can decide the sort order in which the nodes are displayed. We can sort based on various criterias such as node id, title,created date, last updated date etc. Sorting can be done either in ascending or descending order as well based upon user selection.

Fields: Here we choose the actual fields to be displayed in the page. For Basic content type give the Node title and body, for custom content type you can choose other fields as well according to your wish.

Output styles: Here we can choose the output style, how the output should be shown in front end. It can be in any of the following Table,grid,list,Unformatted. No of items to be displayed in each page can also be set here.

Display settings: We can show our view in Page,Block(sidebars) etc. Add the display type according to the needs. If you want to show your view in page display Enter the menu path and select which type of menu you need (Normal menu item, tab,no menu etc).

After updating each setting you can preview the results by clicking the preview button. You can also view the generated query here.

All changes will be saved only when you click the save button.

Some Practical usage of Views Module:

1. To list the recent Blog posts in your website.
2. Recent comment lists in your blog.
3. Recent Posts sorted according the date.
4. To display members/users details of your website in a Page.
5. To show Photo gallery/video gallery in your website.
6. To Display Archives in your site.

The information Presented in this article is very basic, the main purpose of this article is to give a short overview of views module without any complexity/abstraction.
If you Need a detailed explanation about each and every part visit the below links.



Please feel free to leave your comments.