Drupal Interview Questions and Answers

Drupal Interview I have listed down 10 commonly asked Drupal interview questions and answers. Wish you a good luck for your interview!

It is very important that you also quick review how to setup drupal on your local and try to walk through admin UI which gives you more insight.

10 Commonly Asked Interview Questions and Answers.

1. Why do you think Drupal is powerful & popular CMS compare to others?

Drupal Allows to create multiple content types using content construction kit (cck) without any programming skills. Also allows customize theme template for each content type. For example you can create page, article , story, slideshow content types.

Related Reading on DGlobaltech.com

Using drupal “URL Settings” and “Pathauto modules, user can have seo friendly urls for the site.

Taxonomy Terms are the most powerful keywords hierarchy, which provides category based organized information. For example – for politics – you can have articles under “Fiscal cliff”, “election”.

Drupal has most powerful search system than other cms application. Also, Drupal provides many opensource ready to use modules to customize website as per requirement without any programming knowledge. All, these points make “Drupal” as popular CMS.

2. What makes “Search” in drupal as an excellent feature than Other CMS?

Drupal uses search indexing using content type, classification information from taxonomy system and the content meta data.

Drupal treats its content as fine-grained semantic information that Drupal knows about can be used to fine-tune search results.

Also, you can tweak and override the search system to adjust the user interface, the way content is ranked, and the way results are displayed. That said, Drupal integrates well with external search engines such as Apache Solr, Xapian, and Sphinx if the built-in search does not meet your needs very easily.

3. What is a Module in drupal ?

A module is software (code) that extends Drupal features and/or functionality. Drupal Supports – Core modules – included with the main download of Drupal, and you can turn on their functionality without installing additional software. Contributed modules are downloaded from the Modules download section of drupal.org, and installed within your Drupal installation. You can also create your own module – CustomModules” using PHP programming, and Drupal’s module API.

4. What modules do you always recommend and why?

  • Views – This module is essential in every website I build. It makes displaying lists of content very easy. If you want an image slideshow, a list of blog posts, a list of products, etc., views is the best place to start.
  • Panels – Panels gives you the ability to create custom pages easily. These custom pages can have multiple regions of content. For example, you may want to create a home page that has a Slideshow on the top, and a two column layout below.
  • Ctools – On its own, Ctools does not seem to do a lot. However, it is actually a very powerful framework if you begin developing your own modules. I have used Ctools in the past for developing multi-step forms, modal dialog boxes, and even multi-step forms inside of modal dialog boxes.
  • Token – Tokens are little snippets of text that can be used as replacement patterns. For example, if your website sends out emails and you want to add in the users name, or you want fill in a link path with a node id to provide a helpful link to content, tokens will save the day.
  • Pathauto – The Pathauto module is a necessity for any website that frequently adds new content. It is also especially important if you have a website that allows users to create content using content types. Pathauto simplifies creating clean and search engine friendly URLS for the various content you add to your site.
  • Webform – If you want to provide easy to fill out forms for the visitors of your site, the Webform module will help you out.
  • Rules – Drupal rules will allow you to set up condition actions.
  • Date – This is useful for allowing the easy selections of dates in content types (with a nice date popup). It also integrates nicely with the views module.
  • Quicktabs – Makes it easy to add tabbed content without having to write your own Javascript/Jquery. What more do I have to say?
  • Libraries – Makes organizing your various libraries of functionality easy (see Jquery UI above for an example).
  • Google Analytics – I don’t build a Drupal website without adding Google Analytics. This module makes it very simple. What gets measured, gets improved after all.

5. What are hooks in Drupal ?

hooks are drupal api code which allows module to interact with the Drupal core. Drupal’s module system is based on the concept of “hooks”.

A hook is a PHP function that is named foo_bar(), where “foo” is the name of the module (whose file name is thus foo.module) and “bar” is the name of the hook.

Each hook has a defined set of parameters and call back functions to trigger functionality on specific event.  For example if you use form with submit button, on submit event you can have specific functionality.

6. How does caching work in Drupal?

Drupal caching system allows customized settings to speed up website using different configuration with page caching, block caching and lifetime for cached pages.

Page caching:

  • If enables, page caching will only be used for anonymous users.
  • If you enable page caching, the entire HTML of each page will be stored in the database. This significantly reduces the amount of queries needed.
  • This automatically means that blocks will also get cached, disregarded their own cache settings.
  • If Varnish is configured, this will also enable varnish caching
  • The page cache max-age will be used (see below) for each page.
  • You can check the “X-Drupal-Cache” HTTP header to check if this cache is HIT.

Block caching:

  • If you enable block caching, without enabling page caching, the block cache settings will be used (for anonymous and authenticated).
  • The defaults for most blocks is “don’t cache” because that is the default for blocks who don’t have their cache settings specifically declared.
  • You can use block_cache_alter module to set this for each block.
  • When it’s block created by Views, you can set the cache settings for a block in Views.

Minimum cache lifetime:

  • This is the amount of time before the page cache is cleared.
  • Page caches are cleared on each cron run (system_cron).
  • Be warned: incorrect settings of your cron and this setting might kill your website performance. See also this issue.

Expiration of cached pages:

  • This only applies for external caching mechanisms, for example your browser cache or Varnish.
  • It sets the Cache-Control max-age value in the HTTP-HEADERS.
  • This setting only takes effect when page caching is turned on.

  Continue Reading Questions…Page 2…

READ : CSS Most Commonly asked Interview Questions and Answers

READ : SQL most commonly asked : 15 Interview Questions and Answers