I wish I had a list of what to start with when first digging into Drupal, so I’m going to use this post as a place to list out a good starting point for users that have never used Drupal before.
Note: It’s geared towards a Drupal 6 project, BUT I believe most if not all of these will work the same on a Drupal 7 project.
When thinking drupal you have a few key terms / things…
First DON’T ALTER CODE OR PUT STUFF IN A FOLDER IF IT’S NOT UNDER THE ‘sites’ FOLDER. Just don’t, it’s tempting as a new-comer but don’t.
Node: Content is generally saved as node, there are different node types, and you can create your own. e.g. Page is a node type thats generally default. Nodes usually also have urls.
User: users are core to the site. Separate from nodes, users can own nodes.
Module: A folder containing php files and other things like css or js files to add functionality. Modules can be installed by placing them in the sites/all/modules folder, and
Now for a list of things to do to learn more.
Also: I’m going to skip the basic ‘download drupal and get the site installed’ stuff, this is after you get the site downloaded and you can see the first drupal page.
1. Set up 2 sites to run off a Drupal install locally.
Understanding the basics of multi-site Drupal installs is important. In our development team, we use it to allow multiple developers to commit their own local database connection settings at times to their own sites/ folder subfolder.
Use your hosts file to mimic this, pointing something like site1.local and site2.local to your apache server, then using a virtual host with a couple server alias’s settings to drive both urls off one site.
Doing that will force you to understand how the sites/url/settings.php is configured. Read the documentation in the settings.php file in the sites/default folder of a fresh Drupal download, and it will tell you how to name folders to do so.
2. Install and become familiar with Drush.
Drush is awesome because it allows you to update / install modules and do stuff like clear cache via the command line. It’s also a great way to interact with Drupal via the cron, if ever you need to do specific thing via cron.
Drush is not something you install per drupal build, it’s installed per computer. It just lets you use the command line to type “drush” and get the following to show up. From there you also see all the commands you can use through drush. Check out ‘cache-clear’, ‘sql-dump’ and other SQL commands to name a few.
$ drush Execute a drush command. Run `drush help [command]` to view command-specific help. Run `drush topic` to read even more documentation. Global options (see `drush topic core-global-options` for the full list).: -r <path>, --root=<path> Drupal root directory to use (default: current directory) -l http://example.com:8888, URI of the drupal site to use (only needed in multisite environments or when running on an alternate port) --uri=http://example.com:8888 -v, --verbose Display extra information about the command. -d, --debug Display even more information, including internal messages. -y, --yes Assume 'yes' as answer to all prompts -n, --no Assume 'no' as answer to all prompts -s, --simulate Simulate all relevant actions (don't actually change the system) -p, --pipe Emit a compact representation of the command for scripting. -h, --help This help system. --version Show drush version. --php The absolute path to your PHP intepreter, if not 'php' in the path. ... ... ...
3. Handy modules
Install these, they are generally hand. (Note, modules can be found at http://drupal.org/project/modules. And be aware of the version of Drupal you are using when searching.)
- (Drupal 6 only) is the Administration Menu: a handy interface for when your logged in with admin rights. Just adds a black-bar at the top for easy navigation.
- Backup and Migrate: (note the Drush commands added after enabling this.) Allows for very easy database dumps / imports via the Admin interface and Drush.
- Pathauto: Allows for very handy customization of node urls, keeping them automated. A must have for many sites.
- (Drupal 6 only, as it’s included with Drupal 7) Content Construction Kit (CCK): Allows you to add custom fields to your custom content node types.
Thats it for now.
This is very handy, it’s a great way to navigate the site as the admin.