Showing posts with label drupal. Show all posts
Showing posts with label drupal. Show all posts

Thursday, July 3, 2014

109. Core Modules in Drupal 6, Drupal7 and Drupal 8

Sunday, June 29, 2014

107. What is a sub theme in Drupal ?

Sub-themes are just like any other theme, with one difference: They inherit the parent theme's resources. There are no limits on the chaining capabilities connecting sub-themes to their parents. A sub-theme can be a child of another sub-theme, and it can be branched and organized however you see fit. This is what gives sub-themes great potential.

Thursday, June 26, 2014

106. What is template.php in drupal ?

If you want to override a theme function not included in the basic list (block, box, comment, node, page), you need to tell PHPTemplate about it.
To do this, you need to create a template.php file in your theme's directory. This file must start with a PHP opening tag but the close tag is not needed and it is recommended that you omit it. Also included in the file are stubs for the theme overrides. These stubs instruct the engine what template file to use and which variables to pass to it.

Tuesday, June 24, 2014

104. What is entity api module ?

The entity api module extends the entity API of Drupal core in order to provide a unified way to deal with entities and their properties. Additionally, it provides an entity CRUD controller, which helps simplifying the creation of new entity types.


Friday, April 25, 2014

Drupal Job Interview Questions and Answers ( a set of 50 questions, q52-q101)

101. What hardware does Drupal.org run on?

People often wonder what kind of hardware drupal.org runs on. Throughout the project history this has been a tough question. For a while it was a server in a random office building. That server eventually died and required a fund-raising effort to replace (the funds were raised in 24 hours!).
The critical infrastructure is all configured to share the load and be redundant. For example, db1 and db2 are configured to be master-slave most of the time to provide for better performance and allow the slave to be promoted to master if the master fails.

100. Drupal and Working with JavaScript

Drupal provides methods for implementing JavaScript. Using these methods will help to keep your code clean and to ensure compatibility with the way other modules implement JavaScript.
A couple of simple principles guide Drupal's JavaScript approach:
·     All pages should be perfectly functional without scripts. JavaScript provides alternatives or supplements - not replacements - for standard elements.
·  
       No JavaScript is hard-coded into pages. Rather, actions are attached dynamically to page elements--and only if the needed JavaScript support is present.


99. Why does Drupal need a database? What databases are supported?

Drupal stores its information - the individual pages, the registered users, and so on - in the database. The database forms the back-end for your Drupal site. At this time, Drupal supports MySQL (or an equivalent such as MariaDB), PostgreSQL, and in Drupal 7, SQLite.

98. How to create a static archive of a Drupal website

93. Explain drupal advanced search

When Drupal does a search, and returns no results, an advanced search form is displayed. The form contains a list of content types and below fields.
1. Containing any of the words
2. Containing the phrase
3. Containing none of the words 
And users can choose the search criteria if they are not able to find what they want from basic search.

Monday, April 21, 2014

76. Explain Backward Compatibility in Drupal ?

Backward compatibility for data, not code

Everyone considering Drupal should understand that Drupal development is always on the cutting edge, and with each major release there will be radical improvements. (For more information on what Drupal version numbers mean, please see:http://drupal.org/handbook/version-info.) While the upgrade path will reliably preserve your data, there is no backward compatibility with the previous Drupal code.

 

Why ignore backward compatibility?

1.      Each new major release of Drupal contains many, often radical, improvements in functionality, scalability and usability.
2.      These advancements are made possible by not maintaining backwards compatibility with previously released code (however, stable and reliable upgrade paths are part of the planning for each and every release).
3.      There is ALWAYS a path for updating your site with Drupal core.
4.      Only the current stable release series and the previous release series (e.g., 7.x and 6.x) are supported by the Drupal development community at any given time.
5.      As a result, each major release of Drupal will eventually age to the point that it is no longer actively supported by the Drupal community.
6.      Unsupported releases may, in the future, be found to be vulnerable to as-yet-undiscovered or yet-to-be-invented security vulnerabilities.

7.      Therefore, people adopting Drupal for their web or CMS project should plan for periodic upgrades of their project to the latest major release (every 6 years or so) in order to benefit from the ongoing active support of one of the finest open source development communities.

75. Explain Security features of Drupal ?

Drupal has a very good track record in terms of security, and has an organized process for investigating, verifying, and publishing possible security problems.
Drupal's security team is constantly working with the community to address security issues as they arise. More information about this process can be found in that section of the handbook.
Anyone using Drupal should subscribe to the security mailing list (by editing your account profile) in order to automatically keep up to date with the latest security advisories of all types (see below).

 

Is open source software secure?

The short answer is that open source software is as secure or more secure (in general) than commercial software. A good summary of the relevant issues can be found in this article from IBM: The security implications of open source software. The increased security of using open source was cited as one reason the White House switched to Drupal.

 

How Drupal Addresses Common Security Vulnerabilities

Drupal's API and default configuration are designed to be secure when used in their default modes. Issues like Injection, Cross Site Scripting, Session Management, Cross Site Request Forgeries, and others all have standard solutions in the Drupal API. For a more detailed review of the topic please read the Drupal Security Report.

Why does Drupal have more (or fewer) security advisories than another project?

The absolute number of security advisories (especially when including contributed projects) is a totally meaningless number and should never be used for comparison. Drupal has over 7000 contributed projects which are scrutinized by their users for any potential problem, and a security advisory may be issued for a relatively minor issue. For more information read Security Risk Levels
A security advisory also indicates the discovery of a potential problem, and also that the problem is resolved already. It's extremely rare that such security holes are exploited in the wild prior to the security fix being announced in the security advisory. Thus, your most important protection is keeping Drupal up to date whenever a security advisory is issued for Drupal core or contributed code you are using.

On live sites, what vulnerabilities have been found or exploited?

Professional security audits of Drupal sites have generally found that the vast majority of security holes (90% or more) are present in the custom theme or modules written by that site's developers. That code did not get the same public scrutiny that all code on drupal.org receives.
In addition, problems at the server level (such as using insecure protocols like FTP) are more likely to be the means of a successful attack than a vulnerability in Drupal - especially Drupal core.
For information on how to manage security in Drupal, see the Securing Your Site section of the Drupal Administration Guide.


Saturday, April 19, 2014

74. What are Entity types in drupal ?

An entity type is a useful abstraction to group together fields. Entity types are used to store and display data, which can be nodes (content), comments, taxonomy terms, user profiles, or something custom developed.

Read more about Entities in the Entity API documentation.

73. What is Bootstrap in drupal ?

The bootstrap is the CPU (central processing unit) of Drupal. In other interactive software environments this is sometimes called the event loop. Drupal's core is a bit like that. It sits around waiting for a path request, and then starts processing that request.

72. What is drupal weight ?

A term used by Drupal to define the priority or order in which a function is processed or a block / node is displayed. From Drupal 6, the weight field is adjusted dynamically using a drag-and-drop interface. Note: A lower weight value (-10) will float to the top of lists, while heavier (+10) weights will appear lower in lists.