Drupal 7 Tutorial Part 3: Understanding Drupal Node Concept

posted Jun 23, 2011, 12:14 AM by admin@ revitviet.vn   [ updated Jun 23, 2011, 12:24 AM ]

Hi Everyone,

In this tutorial i want to explain basics of drupal terminology. You can work hands on with drupal 7 site by following this Drupal 7 Part 3 tutorial. I assume you already installed drupal 7 and ready to work. If you are not installed find installation tutorial here. http://anilsagar.com/content/drupal-7-tutorial-part-2-how-install-drupal-7

 

Step 1: Please navigate to your newly installed drupal instance. In my case it is http://localhost/d7/ You will see something like below screen.


  • You can see section called user login in left hand side. Using this you can login to your new site. Please login using admin credentials that you given during installation.
  • Once you logged in you will see screen like below.

 

What is a node in Drupal ?

 

  • Each and every piece of content that is created in drupal except comments and blocks is called Node. Basically node is created using content type form. I will explain what is a content type below.
  • So, for example i am going to create new content in my drupal 7 by clicking on Add new content in my home screen. Once you click on Add new content you will see a overlay popup with options such as Article, Basic page. Click on basic page to create a page called About Us.
  • Now you will see a form to create a basic page. Give title as About Us and in body text area write about us content. For example "My name is R Anil Sagar . I am working as senior drupal developer @ SourceN. SourceN is web2.0 shop with expertise in drupal, Java, Jive and iphone app development." Now click on save button at bottom. Don't worry about other options for now i will explain when necessary.
  • Once you click on save you will see a page like below.

 

  • So you just created a page here. It's nothing but a node. Your node has unique id which is called nid. You can see the node id in your url. For us it is node/1 in the url. Nid is 1 here.
  • Instead of basic page if you select article and you create a article still it is a node in drupal. So, basically a node is a piece of content in drupal.
  • In the above example you created a node with title "About Us" which is of type "Page". Type is nothing but "Content Type" which is basically a form to create different nodes of similar type.
  • If i add one more basic page using Add new content option again it will be a node of type "page" with some unique nid. You can see the unique nid in the url after creating page.

Hope you understood the node concept. I will explain advanced node concepts and how nodes are saved in drupal database in my next tutorial.

Cheers,

Anil Sagar

Comments