P. 1
The Drupal Overview

The Drupal Overview

|Views: 118|Likes:
Published by Eric Githua

More info:

Published by: Eric Githua on Jan 06, 2011
Copyright:Attribution Non-commercial


Read on Scribd mobile: iPhone, iPad and Android.
download as DOCX, PDF, TXT or read online from Scribd
See more
See less





The Drupal overview

The Drupal way: manageable abstraction
Effective Web design is driven by the need to balance flexibility and simplicity. If a system is too simple, it can only be used for a single purpose - but if it is too flexible, it may be too difficult for new users to learn. Drupal strives to reconcile these conflicting goals by providing its users with the tools they need to make their own content management solution, while still providing some prebuilt components to help them get started. Thus, it can be described both as a content management system (CMS) and a content management framework (CMF) - one system which strives to have the strengths of both, without their deficiencies. Most CMS's are like a toy boat or toy truck - specific assumptions have been made about their use, assumptions it would be hard for you to override. Frameworks, on the other hand, provide you with raw materials only - you need to know a programming language, and have a clear design vision, to put them together. Drupal is like a Lego kit. Skilled developers have already made the building blocks - in the form of contributed modules - that you need to create a site that suits your needs, whether that is a news site, an online store, a social network, blog, wiki, or something else altogether.

Drupal in action
To make the contrast between Drupal and other CMS's more concrete, consider the example of a news site. You want to be able to post news articles on the site, and you want the homepage to have a section featuring the five most recent ones. Next, you decide that you want to add a blog section, and put a list of links to the five most recent of blog entries on the homepage as well. If you were using an ordinary CMS, first you would install a plugin that handled news articles and could put short blurbs on the homepage. Next, you¶d install a plugin that would track the latest blog posts and put a list of those on the homepage. Each plugin would only be responsible for tracking and managing a particular kind of content, and would remain relatively isolated from the others. But, what happens when you have that brilliant middle-of-the-night idea, and want to blend these two functions by showing a list of blog posts about the latest news items, ordered by most active contributor first? If you¶re using a ³toy truck´ CMS, you may be out of luck, or need to hire a developer to write you a custom plugin from scratch. But through the power of the Drupal way, the way of manageable abstraction, you can whip out a kit full of parts and knock this together pretty quickly. (Hint: just use Views.) Since Drupal's modules do things in a standard way, and interface with a common underlying system, building all sorts of clever, customized features is just a matter of snapping parts together.

Of course, this flexibility comes at a certain cost. While a toy truck is instantly understandable and ready to use without much thought, a modular vehicle construction kit will by nature require you to read the instruction manual first. The building blocks are out there, but you'll need to learn how they fit together before you can take a paper prototype and turn it into a fully-featured website. Drupal core, and the thousands of contributed modules that build on it, require an initial investment to learn, but mastering the Drupal way is immensely rewarding. Drupal's passionate community is a testament to its power to liberate site builders from the simplicity/flexibility dilemma. Once you've tried Drupal, you'll likely leave your toy truck and boat in the closet gathering dust.

How Drupal does it
Intrigued yet? Let's take a closer look at how Drupal works. People often think of a website as a collection of static pages, with some functions (like a blog, or a news engine) thrown in to round it out. When they go to manage their site, they are thinking in terms of a tree-like hierarchy of pages that they will go in and edit. Drupal, on the other hand, treats most content types as variations on the same concept: a node (more on this in a moment). Static pages, blog posts, and news items (some possible node types) are all stored in the same way, and the site's navigation structure is designed separately by editing menus, views (lists of content), and blocks (side content which often have links to different site sections). It¶s a lot like the separation you find in standards-compliant page coding²XHTML provides the meaningful structure of the information, while CSS arranges it for presentation. In Drupal, nodes hold the structured information pertaining to a blog post (such as title, content, author, date) or a news item (title, content, go-live date, take-down date), while the menu system, as well as taxonomy (tagging of content) and views, create the information architecture. Finally, the theme system, along with display modules like Panels, controls how all this looks to site visitors. Since these layers are kept separate, you can provide a completely different navigation and presentation of your content to different users based on their specific needs and roles. Pages can be grouped differently, prioritized in a different order, and various functions and content can be shown or hidden as needed.

Nodes: The secret to Drupal's flexibility
We don't talk about "nodes" every day, but since they are at the heart of Drupal's design, they deserve further investigation. At its most basic, a node is a set of related information. When you create a new blog post, you are not only defining its body text, but also its title, content, author link, creation date, taxonomy (tags), etc. Some of these elements will be shown by the theme layer when the node is displayed. Others are meta-data that control when the node will show up at all - such as taxonomy or publishing status.

turn on the book module for wiki-like collaboration. and feature sets as there are distinct audiences for your site. you can connect with your database and have your first Drupal site up and running within an hour. and connect with each other . enable commenting on node types. but what happens when you want to give individual blogs to each of your users. . book pages (which provide basic wiki features) and any other you may create. With a simple FTP upload and a few short web-based configuration questions. customized user profiles? What if you want to also integrate that in with forums. Most of a Drupal site builder's time is spent defining what kinds of information you want to store in your nodes. a wiki-like environment. This allows site builders to choose exactly where they want content to show up.Since each item of content is stored as a node. create forums and polls. taxonomy trees. You can define as many navigation schemes.blog posts. news items." With some CMS's. Get started quickly. customize extensively Drupal's flexibility is incredible. and then you can start collaborating. while also generating cross-blog topical digests. views. and links out to elaborate. use taxonomy to give site content structured. and give each user their own gallery of taggable photos? Drupal is designed from the ground up so site builders can delegate content creation. where Drupal really shines is when you want to empower site users to create content. and just start adding content. each can be handled in a standard way by both Drupal core and contributed modules." Comments can be enabled on any node type you choose . blocks (small bits of content. and you can install plugins to handle having a community of users. panels) in which to display them. sorting their contents so that they can be displayed individually with their own skins. Pick one of the included themes. and contains the same basic information. but they also illustrate the Drupal way. to users. since there isn't a separate "blog system. but installing it is surprisingly easy. and exactly how they want it to look in each case. Want to switch on some of the included tools? Turn on forums. All you have to do is define who gets to do what on your site (through user permissions). Do you want to have visitors log in? Switch authentication on or off. and even site administration. However. As suggested before. Collaborative at the core Creating an informational website that broadcasts from ³one to many´ is something that most CMSs do right out of the box.moving from "one to many" to "many to many. Comments aren¶t just part of the blog system. and configuring the structures (menus. Comments are second-class citizens in Drupal compared to nodes. you can set up a blog. hierarchical categorization or free-form tagging. custom themes ("skins" for the site). such as the five most recent blog articles described earlier). you aren't limited to a single way of presenting your site's content. top five lists.

it must be input as data. There are five main layers to consider: 1. No old-school tables. Before anything can be displayed on the site. 2. No cruft.Do you want your own skin applied to the site? Drupal's theme system uses tiny snippets of PHP that you can insert into the appropriate spots in your design to replace your placeholder Lorem Ipsum text with dynamic content. you should understand how information flows between the system's layers. he Drupal flow If you want to go deeper with Drupal. The next layer up is where modules live. Modules build on Drupal's core . No kidding. Modules are functional plugins that are either part of the Drupal core (they ship with Drupal) or they are contributed items that have been created by members of the Drupal community. standards-compliant XHTML. Drupal¶s generated markup is clean. At the base of the system is the collection of nodes²the data pool.

with some PHP variables intermixed. Did you forget to place the block. Also included with each theme is a set of functions that can be used to override standard functions in the modules in order to provide complete control over how the modules generate their markup at output time. On the top layer is the site theme (the "skin"). Blocks can be configured to output in various ways. This directional flow from bottom to top controls how Drupal works. This section covers preparing for installation. or you¶d like to assign a CSS class to something? You accomplish this by copying the output function from the module and pushing it up to the functions document in your theme. They represent the innovation and collaborative effort of everyone from individuals to large corporations. Maybe the module is installed and activated. where a number of different Drupal sites run off the same code base. only you wish the markup was just a little bit different? Maybe you¶d like it to use different tags. and when the system goes to output. so Drupal-generated content can go in the appropriate spots. but you still don¶t see what you want on your site. Are you using a module that does exactly what you want. Blocks often provide the output from a module or can be created to display whatever you want.functionality. as in "B"? Or are your user permission settings conflicting with what you want and your users are not set to see the output as in "C"? Additionally²as mentioned earlier²getting the kind of granular control you want over the details of the XHTML module outputs requires understanding this flow. Installation guide Drupal provides an installation script that automatically populates database tables and configures the correct settings in the settings. Next are user permissions. and this is making everything downstream non-functional (as in "A" in the diagram above). Permissions are defined for various roles. or only for certain defined users. 3. This is made up predominantly of XHTML and CSS. It also explains how to do a "multi site" installation. There are thousands of different options within the fastgrowing repository of contributed Drupal modules. This is where settings are configured to determine what different kinds of users are allow to do and see. allowing you to customize the data items (fields) on your node types. At the next layer. Templates can also be assigned on-thefly based on user permissions. we find blocks and menus. as well as only showing on certain defined pages. and then can be placed in various spots in your template (theme) layout.php file. programmatically sorting and display of content (custom output controlled by filters you define). 4. and more. running the installation script itself. and the steps that should be done after running the installation script has completed. users are assigned to these roles in order to grant them the defined permissions. and in turn. Modify the code there. set up e-commerce. 5. . Is some new functionality you want not showing up? Perhaps you uploaded the module into the system but have not activated it yet. it will see your customized function and use that instead.

or specific Drupal support. . System requirements Resources A minimum base installation requires at least 3MB of disk space but you should assume that your actual disk space will be somewhat higher. new modules. phpinfo will tell you if you have a database already installed and what version your system is running. see the Local Server Setup section of the Developing for Drupal guide. which include installation profiles and pre-packaged distributions of Drupal and modules. For information on using other tools. the actual disk space for your installation could easily be 40 MB or more (exclusive of database content. A useful FAQ (http://drupal. For example. Creating a test site on a local computer It is considered a good practice to do all development work on a separate test site before making changes to a production site. Alternative methods for installation Some web hosting companies offer "one-click" installations of Drupal. For help with Drupal terms. Phpinfo will also tell you what php variables are set as well as many other helpful things. modifications to themes etc. For information about setting up a web server on a local computer.org/node/59680) explains how to use phpinfo to get the details of your system. A test site allows you to evaluate the impact of upgrades.Before proceeding with your first Drupal installation. see the terminology page. Other tools Some of the steps in the installation process can be performed with tools such as graphical applications for moving files and managing databases or tools that are provided by your hosting service. For example. if you install many contributed modules and contributed themes. backups and other files). There is also a handbook page listing Drupal distributions. see the documentation that accompanies the application or is provided by your hosting service. Web server Drupal has been deployed successfully on both Apache and IIS. media. You may be able to locate one on the Drupal hosting handbook page. you should also review the best practices section. without causing disruption to your live site. This documentation focuses on performing tasks at the command line. These may be of help as well.

DELETE. For IIS7 you can use the Microsoft URL Rewrite Module or a third party solution. The exact size depends on the version of Drupal you have installed. LOCK TABLES. You can use the Apache 'mod_rewrite' extension to allow for clean URLs. MySQL 4. IIS 6. The total file size of your Drupal installation will depend on what you add to your site.15 or higher. additionally require the following rights: CREATE TEMPORARY TABLES. and version 5. Drupal has been extensively tested with MariaDB.17 or higher.1 or higher.23. It is also likely that other drop-in replacements will work well with Drupal. KB954946 was included in Windows 2008 Server SP2 Drupal is being developed to be web server independent.x.x and earlier supports MySQL 3. NOTE: Drupal makes use of some features not available on some inexpensive hosting plans so please check that your host allows database accounts with the following rights: SELECT. Drupal 7 will only support MySQL 5. INSERT.3 or Apache 2. but Drupal core files alone will take up approximately 2 to 3 MB uncompressed. and also Drupal core 5.x (but not Drupal core 6. but we have limited or no reports of successful use on web servers not listed here. When using Drupal on IIS 7 with fastcgi you must install Hotfix kb954946. These rights are sufficient to run Drupal core 6. There are several drop-in replacements for MySQL. but they have not specifically undergone testing. or IIS 7 if PHP is configured correctly. The majority of Drupal development and deployment is done on Apache.1. or Windows.1 or higher is strongly recommended. . CREATE.x).0. and requires the PDO database extension for PHP (see PHP section below).Apache (Recommended) y y Drupal will work on Apache 1. INDEX. ALTER. so there is more community experience and testing performed on Apache than on other web servers. DROP. UPDATE. To achieve clean URLs you may need to use a third party product. OS X. Database server Recommended: MySQL (or an equivalent such as MariaDB) y y y Drupal 5.x hosted on UNIX/Linux. Some contributed modules. or wait until the hotfix appears in a package update (recommended). Microsoft IIS y y y Drupal core will work using IIS 5.44 (or greater) is recommended. Drupal 6 supports MySQL 4.

3 or higher PHP 5. You might wish to simply create your database and proceed with installing Drupal.x or later.Note: If your system/host is running MySQL 4. it is very likely that you do not need to worry about installing a driver for MySQL -.1 or newer and you receive the error "Client does not support authentication protocol requested by server". A value of 1M may be sufficient for 5.2. In that case.5. particularly with contributed modules.6 for Windows has a bug in its pgsql extension. address the problem by following the instructions provided by MySQL AB. Note that if your web hosting account is set up with a graphic control panel such as Plesk or CPanel. If you are familiar with SQLite please file issues with those contributed modules as you find them.x .dll from version 5. SQLite 3. y y y Drupal 6 supports PostgreSQL 7. you may need to choose a better hosting plan. and then refer back to Drupal documentation for specific troubleshooting help if you run into problems. . NDB tables (MySQL Cluster) are not supported. it may be necessary to set the system variable max_allowed_packet to at least 16M. Note: Drupal supports MyISAM and InnoDB table types.x.2. Note: When using Drupal 5. Some inexpensive hosting plans set this value too low (the MySQL default is only 1M).Drupal 7 only Note: Some contributed modules are not as abstracted from MySQL-specific code as everyone would like.1 or higher Drupal 7 will only support PostgreSQL 8. Please see discussions in the Enterprise Group if you are interested in working on database support.it is probably already installed on your server. PostgreSQL Note: Some contributed modules are not as abstracted from MySQL-specific code as everyone would like. There is a minor OS issue with some MySQL 5+ installations primarily on Windows but affecting some versions of Unix/Linux as well. You will need to replace it with the php_pgsql. If you are familiar with PostgreSQL please file issues with those contributed modules as you find them. Other database engines Microsoft SQL Server and Oracle are supported by an additional module.

An image library for PHP such as the GD library is needed for image manipulation (resizing user pictures. a production site with a number of commonly used modules enabled (CCK. Note: PHP 5. If you have administrator rights on a Debian/Ubuntu server. PHP 5. and pgsql (for PostgreSQL). mysqli (an improved connector for newer MySQL installations). Look in your php.3 is not yet supported by Drupal 5. and GD is not already available (see your phpinfo) it can usually be installed by going: sudo apt-get install php5-gd or on Redhat/Centos: sudo yum install php-gd y See the ImageMagick install instructions for your platform if you want that.x no longer enables the mysql extension by default.ini.x. This extension is enabled by default in a standard PHP installation. Drupal. Drupal 6 core requires PHP's memory_limit to be at least 16MB. Please read the links above for installing and enabling your chosen connector.14) and also by Drupal 7. and Ping modules).2.ini-dist / php. (See the Increase PHP memory limit page in the Troubleshooting FAQ for additional information on modifying the PHP memory limit.14.x does not provide the option to select the mysql connector if mysqli is enabled in your PHP configuration. GD is included with PHP 4. Some installations may require much more.x Required: PHP version 4.3 and higher and usually enabled by default. Drupal's currently supported database connectors are: mysql (the original MySQL extension). Warning messages will be shown if the PHP configuration does not meet these requirements. Work is ongoing to change this to E_ALL for Drupal 6 and Drupal 7. Drupal 6.2 or higher will be a requirement for Drupal 7. o safe_mode: off. Uncomment (remove the leading semicolon) at line .3 configurations still show warnings with Drupal 6.x.0 or higher (Contributed modules may not support this version of PHP) y y y y y y PHP 5. and Drupal 7 core requires 32MB.) The PHP extension for connecting to your chosen database must be installed and enabled. especially with media-rich implementations. work is ongoing to resolve the latter in #360605: PHP 5.14 core and higher (see the release notes for 6. PHP memory requirements can vary significantly depending on the modules in use on your site. o Php Data Objects (PDO) must be activated for Drupal 7 to install and run correctly. while these values may be sufficient for a default Drupal installation.PHP Recommended: PHP 5.3 Compatibility. If you are using a hosting service it is important to verify that your host can provide sufficient memory for the set of modules you are deploying or may deploy in the future. ImageMagick is also supported for basic image manipulations in Drupal core but there is much less support from contributed modules. Views etc. and that some PHP 5.ini-recommended): o register_globals: off. However. but is supported by Drupal 6.) could require 64 MB or more.3. Safe mode may interfere with file and image uploads. the Windows version of PHP has built-in support for this extension. Additionally. PHP XML extension (for Blog API. image and imagecache modules). PHP needs the following configuration directives for Drupal to work (only directives that differ from the default php. Note that some contributed modules may not be compatible with PHP 5. this is the default value. but some hosts have it enabled o error_reporting set to E_ALL & ~E_NOTICE.4.

e.e. browsers have varying levels of compliance with Internet standards such as CSS 2. It is also possible to use a browser that does not support CSS with Drupal. For instance. Drupal 7 may require the time parameter to be at least 30 seconds. In some shared hosting environments. that setting PHP configuration options from . Here is an incomplete list of browsers that are known to work well with Drupal core and support all of its features: y y y y y y Internet Explorer 6. o In addition. we recommend the following setting: session. i. but you will use an interface more like Drupal 5. you can use a drag-and-drop interface to position blocks on the Blocks administration page (admin >> site building >> blocks). If these lines are not there. If you don't have JavaScript. .x and later Google Chrome It is also possible to use a browser that does not support JavaScript with Drupal. access to these settings is restricted. contributed modules) are compatible with.htaccess file that ships with Drupal.htaccess file is actually read. extension=php_pdo_mysql. Browser requirements Websites built using just Drupal core (i. however. in Drupal 6 running in a browser with JavaScript enabled. so you shouldn't need to set them explicitly. If you find a problem with browser compatibility in a contributed module or theme. in all modern browsers that support CSS and JavaScript. More information can be found on the What is PDO page.x and later Camino 1. where you will assign numerical weights to the blocks.x and later Firefox 2. you will still be able to position blocks. Some contributed modules and themes may not be compatible with all browsers. The PECL version of PDO is not compatible with Drupal 7 and cannot be used.cache_limiter: nocache Some of these settings are contained in the default .dll.y y y y extension=php_pdo. you will need to add them.htaccess only works under the following conditions: o With Apache (or a compatible web server) o If the . with no additional. although the functionality will of course be slightly different. If you cannot make these changes yourself. Note. However. so there may be minor variations in appearance.x and later Opera 7 and later Safari 1. or some functionality in a contributed module that does not work at all without JavaScript enabled. but of course the site will not look very similar to how it looks in a browser that does support CSS. please submit an issue to report it to the module or theme maintainer. and fully functional. AllowOverride is not None o If PHP is installed as an Apache module See the PHP manual for how to change configuration settings for other interfaces to PHP. please ask your hosting provider to adjust them for you.dll.

org/project/devel. Menu entries expanded for drop down menus + path aliases + logged in users in D6: http://drupal. In the absence of definite information. and it's fairly easy to run into this problem once you start adding contrib modules. Capacity Planning There are no definite figures available for Drupal's resource requirements. See the time saved by Drupal CSS and Javascript merging. "Is it reasonable to expect 100s of simultaneous connections" http://drupal.Simultaneous MySQL Connections .Known Issues It's worth mentioning here that IE6 has an problem with loading more than 30 stylesheets.org/node/312868 Measuring stuff The Devel module. They will vary depending on what modules you have installed. and what proportion log in rather than browse anonymously. http://drupal. See the overhead of adding Google analytics to a page. here are some relevant discussions: Need suggested baselines for Server Resource Requirements It would help to know baseline requirements for Drupal and just the Core Modules: . how many users you have. counts database calls and execution times. .CPU Thresholds The following discussions state: "Drupal regularly makes more than 100 queries per page load" (Does 1 query = 1 connection?) http://drupal. Firefox Firebug measures and displays the download times within the browser.Simultaneous PHP Connections . (for many sites.org/node/190070 Some combinations of modules and options have a big impact and would be worth measuring in D7.org/node/625898 Executed 595 queries in 207 milliseconds.) See the overhead of splitting a CSS file into two files for easier maintenance. it is the slowest download.

An add on module in D6 might add a special table with one row per node. Check the impact of Fields in your favourite add on modules. Measure for both anonymous users and logged in users. especially if the theme creates problems with CSS or Javascript merging. You might find an alternative module that performs the reads less frequently and caches the result.Measure your Drupal 6 configuration and modules to see what has the greatest impact on performance then look in the issues to see if there are major changes for the D7 versions. both positive and negative. That extra overhead might occur once every 5 minutes for anonymous users and once every page for logged in users. Remeasure after adding a module. PDO is not an abstraction layer like PearDB. a significant difference for logged in users. You could be adding hundreds of menu entries to an otherwise small small menu. Remeasure after changing themes. PDO is a more like a data access layer which uses a unified API (Application Programming Interface). In D7 the same module might add a field to the existing node fields. either document the problem or open an issue for possible improvement. Now do something as simple as listing your main menu and select Expanded for items with a lot of children. This means developers can write portable code much easier. Check known Drupal 6 performance problems in D7. Some themes add their own file and database accesses. The change from separate tables to a single table might make things faster by reducing accesses. Where the impact is similar. Some parts of D7 are different and some parts hardly changed. A feature might add hundreds or thousands of database calls. When you add a cloud display module. consistent way to access databases. An example: Adding path aliases in Drupal 6 had the side effect of adding a database call for every entry in the menu. What is PDO? PDO is an acronym for PHP Data Objects. to the module developers. The change might also slow things down because the separate table uses an index for a lookup while the merged table uses a standard row by row search. . Run Firebug to compare the CSS and Javascript file downloads. How to enable PDO To enable PDO configure --enable-pdo and --with-pdo_sqlite --with_pdo_mysql or whatever database needs supporting by PDO. you might add a read of every node for every display. A logged in user will get a fresh menu on every page view. If you know of something that had a big impact in D6 then check it in D7. Combine that with hidden entries behind drop down menus and you could have a big overhead. PDO is a lean. It is worth reporting the results. Remeasure after changing a setting.

then modify the installed extensions to include these two. Basic installation The following is a simple guide to create a Drupal site in a few easy steps. Upload all the files inside your drupal folder into the web root folder. a web server such as Apache. To follow these steps. or check out the installation troubleshooting guide. a database such as MySQL." Save and continue. on a Unix/Linux command line. Extract the Drupal files. which starts with: "Select an installation profile. Make a note of the username and password. Step 3: Make the sites/default directory writable. You will get a file called drupal-x. un-comment or add the appropriate lines in php. PDO DLLs are not enabled by default.) First there are steps for Drupal 7. then for Drupal 6 below.Windows users y y For Apache. read a more detailed version of these instructions.x. The preferred method for enabling them is to go to the Control Panel | Add/Remove Programs. Create a user.g. . highlight your PHP installation and click "Change" (Change/Remove . you will need to make sure php_pdo. Step 2: Create a database y y Create a new database through your hosting provider's control panel. y For example. and PHP.dll exist in the php/ext directory. and grant the user full rights on the database. This will take you to the Drupal installer." Save and continue. Log into your server using your SFTP client and navigate to the web root directory.tar.ini. use this command: chmod a+w sites/default Step 4: Install y y Browse to your new Drupal site. Drupal 7 Step 1: Download y y y Download the latest version of Drupal 7. For IIS. add that user to the database. You can also skip to the command line quick install guide for developers. you will need a SFTP client such as WinSCP or FileZilla. Make a note of the database name.dll and php_pdo_mysql.XP). Specify "FastCGI".gz. Choose "Standard. and a web server that meets a few basic requirements (e. They are very similar. and restart the web server. then restart your server.

Save and continue.com. and password. Choose the type of database you created (e. Log in to your new Drupal site.y y y y Choose English or learn how to install Drupal in other languages. On the site information page. Save and continue. . the username. Enter the name of the database you created. create tables. The base URL is defined in your Web server configuration file and is specific to the document root where you placed your Drupal files. you can set the site name and email from which the site will send out mail. If you have installed Drupal on a Web server this will likely be a domain name such as http://example. Step 4: Run the installation script For Drupal 6 To run the install script point your browser to the base URL of your website. You also set the username. If you have installed Drupal on your desktop machine this URL might be http://localhost. email.g. You will be guided through several screens to set up the database. MySQL or SQLite). Save and continue. and password of the first administrator account.

add the first user account and provide basic web site settings. .

If you get any errors regarding the files directory and its permissions. point your browser to the base URL of your web site. The "base URL" means the document root (directory) where you placed your Drupal files (and is . see [#394704]. For Drupal 7 To run the Drupal install script.

then you should point your browser to the subfolder (e. The minimal profile has only three modules enabled: Block.settings. follow the instructions in Step 2: Modify file permission. . You can correct the settings individually and either refresh the browser screen or click 'Try again' to see whether there are any errors left. If you have installed Drupal on a web host this will likely be a domain name such as http://www.example. and Update status.    sites/default/files sites/default/private sites/default/private/files These directories should be set to the following permissions chmod o+w sites/default/files OR chmod 777 sites/default/files o Missing settings. you will be informed at this step.php and settings. If you have installed Drupal on your desktop machine this URL might be http://localhost/drupal. but this may fail due to permission settings.com.defined in your web server configuration file). or add additional ones. 3.g. Select a language If you want to install using a language other than the default English. Database logging. http://example.php is missing or not accessible. The "minimal" option is targeted toward more experienced Drupal site creators who wish to set up their own content types with associated publishing options. Most people should select the "standard" option.example. and with appropriate publishing options already set.com/subfolder).php or incorrect permissions If settings. You will be guided through several screens: 1. add the file name "install.php). such as Article and Page.php files. click the Learn how to install Drupal in other languages link.php" (for example http://www. 2. If you installed Drupal in a subfolder. Choose which profile to use for the installation (standard or minimal).) The standard profile also has a useful collection of modules pre-enabled for you. Possible errors include: o Missing directories and/or incorrect permissions The installer will attempt to automatically set up a number of directories. (Of course you can later edit these default content types and their settings. If the installation process does not simply appear by entering the base URL of your site. Note that you will need both the default.com/install. In this case you will find the missing directories listed. Verify requirements If your installation directory is not yet configured properly. The standard option comes with default content types already enabled.

The account you set up in the Site maintenance account section during installation is a super-user who has overall control over every aspect of the management and configuration of the site.2. if you have restricted Internet connectivity (for example if you are behind a corporate firewall) you may want to leave these settings unchecked and test them later. E-mail address. Often updates relate to security issues and are important to perform. these will be created in the next step. the next page will automatically load in your browser. You can also change the port and the table prefix.) o o In the Server settings field. Set up database Enter the database name as well as the username and password for the database that you created in Step 3: Create Drupal's database. (This will be www. enter the e-mail address that will be used by Drupal when it sends out notifications such as registration information.11/bin/php. Note that there is a distinction. review and correct them now. If there are any error messages. The table prefix is useful if you are installing multiple instances of Drupal tables that share the same database. select your Default country and Default time zone. and password for the main administration account. 6. enter the Username. as of Drupal 7. Note that this is not the username and password for administering Drupal. The Advanced options will allow you to change the database host ('localhost' is usually used in this entry: wamp/bin/apache/Apache2. . for those of you familiar with that account from earlier versions of Drupal. Install profile A progress bar will appear and display notes from the installer regarding the progress of the installation. You can also edit it later through the administration interface. o In the Site maintenance account field. and the "Administrator" site administrator user role that you will see when you visit the "Roles" and "Permissions" pages in the administration interface. 5. This username and password information allows Drupal to access your database. On success you will see the Drupal installation complete screen.4. o In the Site e-mail address field. Click "Save and continue". If no errors are encountered.com/user/1. However. between the main administration account that you set up on this page. In the Update notifications field leave both boxes checked if you want your Drupal server to alert you when updates are required. Configure site Input the information for the first user account (which will be automatically assigned full administration permissions) and provide basic web site settings. so the install script can create tables.ini as an example of the location on a Windows box running WAMP). Click Save and continue at the bottom of the page. o In the Site name field enter the name you wish to use for the site.example. You only need to change the port if you are using a non-standard port number.

a=r sites/default/settings.tar. and password.php If you make manual changes to the settings. This will take you to the Drupal installer. add that user to the database.php OR chmod 644 sites/default/settings.php file is at sites/default/settings. and grant the user full rights on the database. you will find the default. (On a Unix/Linux command line: chmod a-w sites/default). Step 4: Install y y y Browse to your new Drupal site.php. Change the permissions on the settings. Step 2: Create a database y y Create a new database through your hosting provider's control panel. Log into your server using your SFTP client and navigate to the web root directory.php file to be writable. (Although the default location for the settings. the username. . MySQL or SQLite). remove write permissions for the settings. Make a copy of this file and rename it to settings. Start filling out the form. Create a user. be sure to protect it again after making your modifications.o=r.php file. (On a Unix/Linux command line: chmod a+w sites/default). Step 3: Create the configuration file y y In your /sites/default folder. You will get a file called drupal-x.php file. chmod u=rw. Make a note of the username and password. Enter the name of the database you created. choose the type of database you created (e. Save and continue. it may be in another location if you use the multi-site setup.gz.) Drupal 6 Step 1: Download y y y Download the latest stable version of Drupal 6.php file to remove write permissions.settings. Extract the Drupal files. Make a note of the database name.x. Change the permissions on the /sites/default folder and the settings. When you get to the database screen. Failure to remove write permissions to that file is a security risk.Secure your site After the installation is complete. Upload all the files inside your drupal folder into the web root folder.php.g.php file later.

Copy the default.php and settings. NOTE: Do not simply rename the file. Quick install for experts This page provides a summary of the command line instructions for installing Drupal on a typical UNIX/Linux web server.php.y y On the site information page. 4.settings. chmod a+w sites/default NOTE: Do not forget to change permissions back after you have run the installation script.php Both commands have the same effect. Log in to your new Drupal site. It must be copied and the new file must be given the correct name. check both the Read and Write boxes for "Owner". If your ftp client has checkboxes for setting permissions.php file in your sites/default directory. so that the installer can edit it. 3. Save and continue. You also set the username. Several FTP tools like Filezilla. NOTE: Do not forget to change permissions back after you have run the installation script.php. You should now have both a default. "Group".settings.php file and set some permissions.php or chmod 666 sites/default/settings. 1. If you have problems. using chmod a+w sites/default/settings. To let the files directory be created automatically. Step 3: settings. email.php sites/default/settings. read Troubleshooting common problems. .settings. Transmit. give the web server write privileges to the sites/default directory. The default file is not used by the installer. and "Others" (leaving the Execute boxes unchecked). In this case the octal or numeric value file permission should be set to 666. using a 'file attribute' or 'get info' command. and Fetch allow you to change file permissions. Every step contains a link to more detailed installation instructions where you also can find information about installing Drupal on other systems.php. you can set the site name and email from which the site will send out mail.php to settings.settings. Settings. 2.php You must create a settings. The Drupal installer will need both files. and password of the first administrator account. You can do this from the command line (working from the root of the directory containing your Drupal installation) using cp sites/default/default.php Your Drupal download comes with a sample configuration file at sites/default /default. Make the settings file writeable.

cp sites/default/default.settings.tar. You can do this by command line or through phpMyAdmin or another database clients. copy the default.o=rw) to the configuration file.php.php file and name the copied file as settings.Read more about system requirements (among which detailed PHP-settings and browser requirements). chmod a+w sites/default/settings. Windows and Mac OS). you must create a empty database and a user with full access the newly created database for Drupal to use.org/files/projects/drupal-x. /var/www/drupal-x.gz Move the files to a directory within your web server's document root or your public HTML directory using the following command. mysqladmin -u username -p create databasename .php Give the web server write privileges (666 or u=rw.) mv drupal-x.x /var/www/ You can install and use Drupal in other languages by downloading translations from http://drupal. Create the configuration file and grant permissions In the sites/default directory. (On many *nix computers the path from the server's root will be /var/www/.x. chmod a+w sites/default Read more about preparing the configuration file.x.g. Create the Drupal database To complete the installation.php sites/default/settings. 1. wget http://drupal. 2. 3.x) Read more about downloading and extracting Drupal (includes instructions for FTP. substituting drupal-x.gz tar -zxvf drupal-x.org/project/translations.x with the actual version number.g=rw. Download and extract files Download Drupal from http://drupal.settings.tar. Extract the files into the Drupal directory (e.php Give the web server write privileges to the sites/default directory.org/project/drupal and extract the download file to a folder on your hard drive.

ALTER.* TO 'username'@'localhost' IDENTIFIED BY 'password'.com.g.example. see the Drupal version information page. LOCK TABLES ON databasename. Follow the wizard to finalize the installation and start working with your Drupal website. 4. http://www.example. Log in to MySQL: mysql -u username -p At the MySQL prompt. INDEX.Where 'username' is a MySQL user which has the CREATE and GRANT privileges. MySQL will reply with: Query OK. Point your browser to the base URL of your website (e. DROP. and PostgreSQL and SQLite as database). Next you must set the access database rights. UPDATE. CREATE. To learn more about versions. INSERT. 0 rows affected Read more about creating the database (among which instructions on using phpMyAdmin.com/drupal or http://localhost/drupal). CREATE TEMPORARY TABLES. add the first user account. and provide basic web site settings. Run the installation script You are now ready to run the installation script. Step 1: Download and uncompress Drupal Drupal is available in several versions. DELETE. enter: GRANT SELECT. The "recommended release" is the latest stable release. . http://www. The installation wizard will guide you through several screens to set up the database. Where: 'databasename' is the name of your database 'username' is the username of your MySQL account 'localhost' is the server name used to access MySQL 'password' is the password required for that username If successful. MySQL will prompt for the 'username' database password. Read more about the installation script (along with a detailed description of all the available options).

If you are .x.x" with your downloaded version): tar -xzvf drupal-x.tar.tar. or a server that hosts multiple domains..gz Remove the compressed file by typing rm drupal-x.) Uncompressing Drupal Type the following command (replacing "x.tar.org/files/projects/drupal-x. the path will be different -.x. ask your hosting provider for assistance. On many *nix computers the path from the server's root will be /var/www/html.. log in to your server and navigate to the directory from which you will be serving your Drupal site. so cd /var/www/html.tar. Downloading Drupal Before you begin.gz or curl -O http://drupal.x/* drupal-x. Not every computer has both.org/project/translations.gz. the two most popular of which are wget and curl.x/.x. You will need to know this URL before proceeding to the next steps of the installation. Download Drupal using any download utility. If you are unsure of the directory.org/files/projects/drupal-x.perhaps the command cd ~/www or cd ~/public_html will work. Moving Drupal to its intended location Now you need to move the contents of the drupal-x.gz" string with the link for the version you will be installing.x directory one level "up" into the web server's document root or your public HTML directory: mv drupal-x. and you can delete the drupal-x. The commands are: wget http://ftp.gz (Note that the option for the curl command is the upper case letter "O" and not the numeral that stands for zero./ The files from the directory you downloaded and decompressed have now been moved up a level into your web directory.) (Replace the "http://drupal.Information about Drupal translations is available at http://drupal.drupal.x directory (which is now empty): rmdir drupal-x.x Before continuing to the next page . The base URL for your Drupal installation will be set in your Web server's configuration file.x.org/files/projects/drupal-x.x.tar.htaccess . On a shared server.

www. password.example.g. when running the Install script (see next page) the database and user may need to be typed in as "webadmin_drupal7db" and "webadmin_d7user". These tools include easy-to-use features for creating a new database.. if you log into your Web site control panel as "webadmin" and create a database named "drupal7db" and a user for that database named "d7user".installing Drupal on your local machine the base URL may be: http://localhost.) If you have created your database and user via a Web-based interface.com/blog etc.com. To create a database using a browser-based control panel consult the documentation or ask your web host service provider.example. If you are installing Drupal to a Web server your base URL may be a specific domain name (such as http://example.example. and on one server each database and user name must be unique across all accounts on the server. or by creating the database directly from the MySQL or PostgreSQL command prompt (for more advanced users). For example. if you simply check "All" privileges for the user you create (and then uncheck "Grant" if it is listed as a privilege) your user will be set up correctly. . Take note of the username. or by using phpMyAdmin (another browser-based database utility).com). You will enter these items into fields in your browser when running the install script (see next page). (This is because many hosting accounts are on shared servers. and for creating a "user" with rights to the database. are you installing in www. Create a database using a browser-based control panel Most web hosting accounts provide a Web-based control panel to help you administer your site. Step 2: Create the database Before running the installation script. Note that in many cases when creating databases and users via a Web-based graphic interface.com.) as you create the database. When you create the user for your database. the user name you use to log into your control panel is added as a prefix to the database name and possibly to the database user name as well. In most Web control panels' "database wizard". or in drupal. you must create an empty database and database user (a user name assigned the rights to use the Drupal database). you can skip the remainder of this page and continue with the install instructions on the next page. This page offers guidance for creating your Drupal database using a Web browser-based control panel (such as "CPanel" or "Plesk"). you may see a page where you can specify the privileges that user will have for various operations on the database. database name and hostname (e.

If you want to have a different name for database and user. as it limits access to your databases if someone gets hold of your database logins. If you need more details about using PHPMyAdmin. In the Database for User list. 6.com. This is more secure than using a general username & password for all your sites on the same server.Create database and user using PHPMyAdmin This presumes you have root access to PHPMyAdmin 1.example.txt (for PostgreSQL). Enter or generate a password for the user. www.example.) as you create the database.pgsql.mysql.txt (for MySQL) or INSTALL. then operations tab. password.com/blog etc. select Local which is more secure. you can follow the information below. the user name you use to log in to your control panel is added as a prefix to the database name and possibly to the database user name as well. Create a database from the command line If you do not use a Web control panel or are experienced with and prefer to use MySQL or PostgreSQL commands. are you installing in www. . if you log into your Web site control panel as "webadmin" and create a database named "drupal7db" and a user for that database named "d7user". and on one server each database and user name must be unique across all accounts on the server. when running the Install script (see next page) the database and user may need to be typed in as "webadmin_drupal7db" and "webadmin_d7user". 2.example.. database name and hostname (e. You will enter these items into fields in your browser when running the install script (see next page). (This is because many hosting accounts are on shared servers.g. unless you will be accessing the database with this user from another server 5. Take note of the username. enter the username you wish to use In the Host field. and instructions to create a database using the command line are available in INSTALL. Note that in many cases when creating databases and users using a web interface. you can skip the remainder of this page and continue with the install instructions on the next page.) If you have created your database and user via phpMyAdmin. or in drupal. just select the created database. check out the official wiki. Additional information about privileges. Log in to PHPMyAdmin as the root user Click Privileges & Add a new User In the User name field. 3. You will find an option Rename database to. 4.com. For example. select Create database with same name and grant all privileges and click Go You have now created a user that has all privileges only on the database with the same name.

Create a database using MySQL commands For information on installing and configuring MySQL see http://dev. 4. CREATE TEMPORARY TABLES ON `databasename`.* TO 'username'@'localhost' IDENTIFIED BY 'password'. INSERT. 0 rows affected 5. At the MySQL prompt. 'username' is an example MySQL user who will have the CREATE and GRANT privileges and 'databasename' is the name of the new database Use the appropriate names for your system. ALTER. 3. DELETE. mysqladmin -u username -p create databasename MySQL prompts for the 'username' database password. Create a new database for your site.html In the following examples.* for security (underscore is a wildcard). `drupal\_test\_account`. DROP.* should be drupal\_test\_account. CREATE. Eg: drupal_test_account.com/techresources/articles/mysql_intro.* Note: unless your database user has all of the privileges listed above. This requires the ` wrapper. LOCK TABLES. and creates the initial database files. If successful. In this case: o o o 'databasename' is the name of your database 'username@localhost' is the username of your MySQL account 'password' is the password required for that username You will need the ` around the database name if you have used a MySQL escape character in your schema name. UPDATE. set the permissions using the following command: GRANT SELECT. enter the following command: . To activate the new permissions. you will not be able to run Drupal. MySQL will reply with: Query OK. INDEX. 1. 2.mysql. Log in and set the access database rights: mysql -u username -p MySQL prompts for the 'username' database password.

Create the database This step is only necessary if you don't already have a database setup (e. which is owned by previously created "username": createdb --encoding=UNICODE --owner=username databasename If everything works correctly. you'll see a CREATE USER notice. Create a database using PostgreSQL The database must be created with UTF-8 (Unicode) encoding. 1. by your host) or you want to create new user for use with Drupal only. by your host) or you want to create new database for use with Drupal only. . you'll see a CREATE DATABASE notice. The database should be created with UTF-8 (Unicode) encoding. The following command creates a new user named 'username' (you should substitute this with the desired username). 2.g.FLUSH PRIVILEGES. The following command creates a new database named "databasename" (you should substitute this with the desired database name).g. and prompts for a password for that user: createuser --pwprompt --encrypted --no-adduser --no-createdb username If everything works correctly. Create a database user This step is only necessary if you don't already have a user setup (e.

You're Reading a Free Preview

/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->