Crash course: How to make a website with Drupal

Page 3 of 4

Installing a new theme

Next, let's install a new theme. Go to the Drupal themes page, pick one that matches your Drupal version, and download it. Some are free, some cost money, some are developer previews or labeled as minimally maintained, so pick one that sounds like it won't be a batch of new troubles. Then back in your Drupal administration page, go to Appearance, and click Install New Theme. You can install it either from a downloaded file on your computer, or from a Web site. I installed the Alina theme. You'll see a "Installation was completed successfully" message if all goes well. Underneath this message is a link labeled "Enable newly added themes." Click this link and it takes you back to the Appearance page, where you can scroll down to DISABLED THEMES and enable your new theme.

When the new theme is installed you'll get a success message, and also a "No update information available. Run cron or check manually" message. Click "check manually" to check for updates, and to clear the message. Note that you can have a different theme for the administration pages, which is selected on the same page. Figure 5 shows my setup: I have Alina as my site theme, Seven 7.8 as the administration theme, and all the other installed themes disabled.

Figure 5: The Alina and Seven 7.8 themes are enabled, and all others disabled.

I could click the Settings link for Alina to tweak the page elements, but for now I'm leaving it alone, because it is time to create some content. Drupal has three categories for content: Book Page, Basic Page, and Article. A book page is a collection of related entries and links that you can assemble from any of your existing content. (In my installation Book Pages were not enabled. Book pages are part of the Drupal core, and are enabled and disabled in the Modules menu.)

The two workhorses are Basic Page and Article. A Basic Page is for static content like About and Contact pages. Articles are time-sensitive material, like news articles and blog posts. I want to create my About page. Enter the Content menu, click Add Content, click Basic Page, and start writing. You have a choice of three text formats: Filtered HTML, Full HTML, and Plain Text. Filtered HTML gives the most control over formatting, so that's what I use. Drupal automatically creates a teaser from the beginning of your text. There are two ways to control this: click Edit Summary to write a custom summary, or enter the <!--break--> tag in the body of your text where you want it to split. Check "Provide a menu link", enter a title and description, and save.

I still need some front page content, so I'll create an Article. Articles can have menu links, but I haven't created a menu yet for articles, so for now it has no menu link. When the new Article is finished I want it to appear on the front page. Articles placement is controlled in the main Content menu. Figure 6 shows what to do.

Figure 6: Promoting an Article to the front page.

The Content menu shows the two new pieces of content. "September 2011 Linux articles" is checked, and under Update Options I have selected "Promote selected content to front page." Click Update, and figure 7 shows the result.

Figure 7: The new!

Note that there is a "Read more" link at the end of the article. It should not be there, since the entire article is displayed. The issue of uncontrollable Read More links is a source of woe in Drupal-land with no completely satisfactory resolution that I have found. Try Remove "read more" and display entire content for help.

| 1 2 3 4 Page 3
ITWorld DealPost: The best in tech deals and discounts.
Shop Tech Products at Amazon