Changes At Splat And WiseTome.com

Those of you who have been visiting Splat regularly, might have seen a lot of changes that are happening around here in the past 24 hours. These changes have been made after quite a bit of considerations on the mission of WiseTome.com.

The mission of WiseTome is to become a continuously expanding library of articles and information on growing number of topics.

The topics were initially around interests of my own, and after that - around interests of people who joined the wagon. Splat, the blog of WiseTome.com, was meant to be the place-holder for all the information that we came across. We did put some research in to it, but not enough to deem it to be fit in WiseTome.com. And Splat has served the purpose well to that extent. There are 150 short articles on the different categories posted at Splat over the course of roughly an year.

The other things we are involved in made it difficult for us to concentrate on compiling the information we had amassed and put it in a digestible format. This point of time, I will be concentrating on that. So expect to have less frequent or even absent posting at Splat.

Here are some of the changes applied to Splat and WiseTome.com. This process has involved tradeoffs between ideal setup and not breaking anything up.

  • Common theme for WiseTome.com and Splat. Splat is after all a part of WiseTome and to this extent, the Garland theme is used for both. I might put in some customizations, but focus would be on the content. There would be nothing fancy, as the goal of WiseTome.com is to provide information.
  • Common navigation at high level. The main navigation section is a horizontal strip of links that would let you navigate between sections of the site easily. No other URL structure has been changed and that means, none of you nice people who have tracked back to any articles here will be left broken links. All links work as they would earlier.

So - what should you expect for the near future of Splat and WiseTome.com?

  • Less frequent and less regular posting at Splat. I would be working on compiling the mass of information that we have at Splat into WiseTome - so there would be no posts from me. There might be few guest posts peppered. This would be for at least a couple of months if my estimates hold true.
  • Compiled articles at WiseTome. There would be work done at compiling all the works of information from myself and other authors. I am yet to figure out the best way to do it - so if you have any suggestions - you are most welcome.

I think I would be tackling one section at a time. Expect round ups of those works here.

Pretty URLs In Drupal

A fresh Drupal installation would be having URL (Uniform Resource Locators) of the following fashion:

http://www.wisetome.com/?q=node/1

Since Drupal is a CMS that stores all the page and other content data in the database, it has to pass details to the main index.php of what page needs to be fetched. In effect, Drupal will be showing only one page, with dynamic data depending on the parameters passed. If a parameter has to be passed, it is done so by attaching a /?q=

to the domain name. So how do we go about making the URLs from something that is above, to a much more user friendly format given below?

http://www.wisetome.com/about-wisetome

We can use some configuration changes, a core module and a contributed module to achieve this.

Configuration changes

  • After logging in to the Drupal site with your adminstrator login, go to Home > Administer > Site configuration > Clean URLs.
  • Select enable.
  • Save configuration.

Note - you may need to provide write permissions for the .htaccess file in your root folder of your webhost account.

This will change it to something that will eliminate the ?q= by using some URL rewrite rules.

http://www.wisetome.com/node/1

ULR aliases - Path module

You can use the core module, Path, to rename the path to whatever you want.
Read the rest of this entry »

Drupal - Modules

As of Drupal 5, there are six core required modules (Block, Filter, Node, System, User, Watchdog) and around 23 supplied modules that are usually not activated.

The required core modules are - well - required. They cannot even be turned off - so we need not bother learning about them unless we are into custom module development. The other 23 modules are worth looking into, and they usually will supply most of the basic extended functionality you might need.

Help - This module can be turned off, but by default it is turned on and it handles the online help functionality for the various other features of your Drupal website.

Legacy - If you are starting fresh with a Drupal installation - ignore this. This module is provided for backward functionality.

Drupal - This is a module that registers to a central server. With this enabled, all the different Drupal powered websites in the internet, become a sort of ’super-website’ in terms of user base. It lets a user of one website log in to another Drupal powered website. This is generally disabled by default.

Locale - This allowed for using multiple localization UI files that would translate the UI to specific languages.

Contact - This provides the essential contact page. I believe every site must have this, and I enable it for every site I setup using Drupal.

Profile - This module is not so important for a single user website. But if community is involved, then you will want to store more information about your users. The Profile modules lets you define custom fields for the user.

Path - The module allows you to rename the URLs. By default, the URLs would be <yoursite.com>/?q=node/<number>. If you had switched on clean URLs, then it would be, <yoursite.com>/node/<number>. With the Path module, you can rename the URL for any node - <yoursite.com>/<anything-you-want>. (This module combined with the Pathauto module, become a versatile combo that I use for every Drupal powered site).

Comment - This module turns on the commenting system. It can have various setups of who can post comments, and where they end up in the moderation queue.

Poll - This allows you to create polls in your website.

Search - This module starts indexing all your content internally, and provides a versatile search option to search any type of content with in your site.

Ping - This pings other sites whenever new nodes (content) is created in your site.

Blog, Blog API - These two modules are a must have for a site that is setup to run multiple blogs by multiple users. The API module allows you to hook up offline applications to post to their blogs.

Aggregator - This allows you to show links or briefs from feeds (RSS or Atom)

Taxonomy - This module is the gem of Drupal. It requires a write up in itself, but for now, we will leave it by saying that it lets you organize all the content on your site any way you want.
Read the rest of this entry »

Drupal - Initial Setup

After setting up a handful of Drupal powered sites, it has formed a habit on setting up the different modules and themes that put the site on a ‘ready to go live’ or ‘ready to build upon’ state. This basically involves going through a set of items and options in the Drupal administration area and setting them up.

In this article, I will be assuming a Drupal 5 installation. The Drupal 6 would be having what are called ‘install profiles’ that will actually ask few questions and setup these basic setups for you.

Site name, description, mission, copyright info

Once Drupal site is installed and the first user (the super-user) is created, login with it and proceed to ‘Home › Administer › Site configuration > Site Information’ and fill in the details like the site name, slogan, mission statement, and copyrithg info. I like to put this one before setting up anything else, because once these details are put, it lets me identify the Drupal instance easily by the website name instead of the default ‘Drupal’ title.

Status Report

This step lays down the crucial baseline and ensures that whatever you build and setup over it need not be rolled back. Go to ‘Home › Administer › Logs > Status Report’ and fix any errors that it might indicate. Usually, the ‘files’ folder is not created, and you would need to create it in the installation directory with proper read-write-execute permissions.

Basic theme selection and customization

Even if I am going to apply a custom theme to the website later, it helps to add direction to the website development by customizing the default themes. Go to ‘Home › Administer › Site building > Themes’ and play around with all the options. Choose a particular theme, and customize it. If you chose Garland theme, then you will be able to tweak the color sheme with the help of ‘Color’ module. You will also be able to switch off the logo or replace it with a custom one here.

URLs

This is a crucial first step in building a search engine friendly as well as user friendly website. At ‘Home › Administer › Site configuration > Clean URLs’, enable the Clean URLs option. You may need to give write access to the .htaccess file while doing this. At this point, you may have trouble with the cookies where it might show an ‘Access Denied’ message even if you are logged in. Just clear the browser cookies and cache and login again. Next, proceed to ‘Home › Administer › Site building > Modules’ and activate the ‘Path’ module if it is not already activated. You are now prepared to install the custom module - Pathauto.
Read the rest of this entry »

Drupal - Installation

Drupal, is one of the choices you may take among the other CMS.  And as I said earlier, there are three things that you need to setup a Drupal powered website - a webserver, PHP and a database.  If these are available, you can install a Drupal instance.

Before I go into a bit of details on how you can install Drupal, let us look at what phases a software undergoes before being actually used by the users.

In simple terms, software needs to be developed, tested and then deployed into production. This is generally how it happens in full blown software development scenarios. Do we need all of this for setting up Drupal?  In my opinion, you need at least two instances of your website. One that is actually visible and sits in a public URL. Another one where you can develop and test the website.

Hosting costs have come down these days, but yet it might not seem prudent to go setting up your test instance on a server. You can setup a local instance quite easily for Drupal.  For setting up a local instance, I usually use the XAMPP package that gives me the full stack of webserver (Apache), MySQL and PHP.  (You can get XAMPP from the Apache Friends website).

The installation is quite simple in the present version of Drupal 5. (It is said that it would be more simpler with the Drupal 6 release).  I will be explaining how it is done for MySQL as the database.

  1. Download Drupal. At this point in time, I would advice for using Drupal 5.2 as Drupal 6 would be coming out soon.
  2. Unzip and put the contents of the folder in your root location. In case of a webhost, it would be in the ‘public_html’ or similar root folder provided for your account. In case of a local instance, and if you have gone for XAMPP, it would be \xampp\htdocs folder.
  3. Go to phpMyAdmin and create a database - give a proper database name so that it is easily decipherable. Create a database user and give all permissions to that user on that database.
  4. Open your browser and give the URL that should point you to the root where you unzipped the contents of Drupal download file.  In case of a webhost, it will usually be the domain name you parked there.  In case of local instance, it will be http://localhost/ or http://localhost/<install folder> depending on how you unzipped the files into htdocs.
  5. This should automatically fire up the install.php - and it is a pretty easy from here on as it is a guided install. Give the database name, database user name, the password, and you should be good to go.

Always have a process in place where you can develop and test your site separately and move the files and database to ‘production’ or live environment. And before making any new changes to your website, take full backups.  It is much easier to restore your website from backups if the changes you put in go wrong. Of course, this is not a problem during installation.

Please use the comment section if you have any doubts or if you need more details.

Drupal - Hosting Requirements

Drupal is an Open Source Content Management system. It is a CMS with which you will be able to build a website.

To install Drupal, the hosting setup needs to meet certain set of requirements. The basic requirements are:

  • Webserver - As common sense as it seems, I get a lot of questions on how one can install Drupal on a PC in order to setup a website. Unless you are running your PC as a server, it does not make sense to ask that question. What you should be looking for, is a hosting account. Drupal needs to be setup on a server, that responds to requests over the WWW through HTTP. It is recommended to have Apache webserver, but you can install it on IIS too.
  • PHP - The webserver must have PHP, in order to process the request and render HTML responses. The version of PHP required is dependent on the version of Drupal you are going to setup. Drupal 4.7.2 requires PHP 4.3 or higher. Only Drupal 4.7.5 (and greater) or 5.0 (and greater) run on PHP 5.x. At this point in time when the post is written, Drupal 6 is under development, and it is recommended to go for Drupal 5.x and PHP 5.x in view of future compatibility.
  • Database - Drupal does not store any of the content as files on the webserver, but stores it in database. Hence, you require a PHP supported database like MySQL or PostgreSQL. It is recommended to use MySQL 4.x (and greater) and in case of PostgreSQL, version 7.3 or greater. The out of the box is fully functional in both the databases, but some of the third party modules might not work on PostgreSQL.

Note that Drupal requires the following permissions for the database - SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES. Ensure that you have access to the database in your hosting account and are able to create database with a user who has the above permissions.

In the next post, we will briefly look at the installation procedure for setting up Drupal in a hosting account.