Maria’s Guides

Support and additional material for readers of books, articles, and digital media by Maria Langer.


Random Book Cover #1Random Book Cover #2Random Book Cover #3Random Book Cover #4Random Book Cover #5Random Book Cover #6Random Book Cover #7Random Book Cover #8Random Book Cover #9

links for 2007-01-01

Posted on December 31st, 2006 at 11:17 pm · No Comments
Filed in: RSS Links Worth Following   

→ No Comments • Read 176 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This


How to List Random Posts in a WordPress Blog’s Sidebar

Posted on December 31st, 2006 at 7:08 am · No Comments
Filed in: RSS WordPress Books   

Draw people into your blog by showing them other posts in the same category.

People browse blogs all kinds of ways. One way is to come in at the Home page and browse what’s there, then click a category link in your navigation bar to go deeper into the site. Clicking a category link identifies a topic that interests them. But how can you get them to keep browsing what’s there when all they’ll see is the few most recent posts displayed there?

imageOne way is to display a random list of category posts in the sidebar (see screenshot right or visit this page for an example). There are a number of ways to do this, but the quickest and easiest (which is usually my preferred method) is to use the Customizable Post Listings plugin by Scott Reilly with a few simple lines of code inserted in your sidebar.

Customizable Post Listings isn’t new. Its latest version (1.1) was released back in 2004. But it still works like a charm — at least in WordPress 2.0.4 on my server. From the description:

Display Recent Posts, Recently Commented Posts, Recently Modified Posts, Random Posts, and other post listings using the post information of your choosing in an easily customizable manner. You can narrow post searches by specifying categories and/or authors, among other things.

I already use it on MariaLanger.com to display recent posts and recently commented posts, so adding another feature that takes advantage of this plugin wasn’t a big deal. In fact, it made sense.

I won’t go into details about how to download and install the plugin. You can figure that out for yourself. If you’re new to WordPress and plugins and need help, I will plug the book I co-authored with Miraz Jordan here: WordPress 2: Visual QuickStart Guide. It has a whole chapter dedicated to plugins. Enough said.

Once the plugin has been installed and activated, open your sidebar.php file (or the file in which you want to include the random post code). Then enter the following code where you want the list of random posts to appear:

<?php if (is_category()) { ?>
<h2><?php single_cat_title('Random Articles in '); ?></h2>
<ul>
<?php c2c_get_random_posts(16,"<li>%post_URL%</li>", $wp_query->query_vars['cat']); ?>
</ul>
<?php } ?>

Keep in mind that this code uses the tags I use in my sidebar for formatting: h2 for sidebar headings and ul for an unordered list. Your HTML formatting may differ, so you might have to adjust this a bit for your site.

The first and last lines of this code provide conditional instructions. They basically say that if the page being displayed is a category page, show the random posts listing. So if the Home page or a single post page is displayed, the random category list does not appear.

The single_cat_title tag is a neat way to customize the heading so it displays the name of the category.

You might also want to change the value in the c2c_get_random_posts tag. I have it set to show 16 posts; you can show more or fewer. If you put a value in there that’s higher than the number of posts in the category, all of the posts will be displayed in random order. But if you want to display all of the posts, why not do it in reverse chronological order? Just replace

<?php c2c_get_random_posts(16,"<li>%post_URL%</li>", $wp_query->query_vars['cat']); ?>

with

<?php c2c_get_recent_posts(150,"<li>%post_URL%</li>", $wp_query->query_vars['cat']); ?>

Remember to make the value big enough to cover all the posts in each category. I don’t know if there’s a limit to the value, but I probably wouldn’t use this if I had more than a hundred or so posts in a category anyway. It would make the sidebar too long. (My opinion.)

Of course, you might want to change the heading, too — something like

<h2><?php single_cat_title('All Articles in '); ?></h2>

would be more appropriate when showing all the posts.

As you can imagine, there are lots of ways you can play with this to list post titles in the sidebar. And if your post titles are intriguing enough, these few lines of code might keep visitors on your site a bit longer.

→ No Comments • Read 1027 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This


Additional Features of the Dock

Posted on December 31st, 2006 at 6:19 am · No Comments
Filed in: RSS Mac OS Books   

Another Apple Technical Note.

Want to learn how you can get the most out of Mac OS X’s Dock feature and the all-too-often-overlooked Application Switcher? Apple’s got a technical note that covers them both.

From Mac OS X: Additional features of the Dock on Apple Support:

The Dock offers useful controls and menus that may not be immediately apparent. You access these additional features with different combinations of modifier keys (such as Option, Control), and with different types of mouse clicks (click versus press and hold). Additionally, learn about Application Switcher, an alternative way to switch between applications without using the Dock or your mouse.

Good reading if you’re interested in tips and tricks for using your Mac.

→ No Comments • Read 227 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This


links for 2006-12-31

Posted on December 30th, 2006 at 11:19 pm · 1 Comment
Filed in: RSS Links Worth Following   

→ 1 Comment • Read 175 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This


Doing a Clean Install of Mac OS 9 from Restore Disks

Posted on December 30th, 2006 at 7:59 am · No Comments
Filed in: RSS Mac OS Books   

An Apple Support Technical Note.

As Mac OS X is revised, the number of Mac OS X users also using Mac OS 9 on their computers (in the Classic Environment) is ever dwindling. As a result, my coverage of Mac OS 9 issues in my Mac OS X Visual QuickStart Guides is shrinking with each revision.

Of particular note are my somewhat vague instructions for installing Mac OS 9 on a Mac OS X computer. My editor decided (and I concurred) that the number of readers who would actually need this material was not significant enough to warrant full coverage. And since the book is getting fatter and fatter (not unlike its author these days — ouch!), trimming has become an important part of the revision process.

Fortunately, Apple has a great technical note that covers the process: “Mac OS X 10.2, 10.3: How to perform Mac OS 9 clean installation with Restore CDs.” In it, you’ll find step-by-step instructions, as well as links to related articles.

I also want to mention here that Apple’s support Web site is an excellent source of help for Mac tasks and problems. The only problem I have with it is the fact that the search feature is so poor that it often comes up with many, many articles that simply don’t address my problem. This might be my problem — my personal inability to effectively use the search features. Who knows? In any case, it’s worth a try the next time you’re stumped while sitting in front of your Mac.

→ No Comments • Read 480 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This


Excel 2007 QuickProject Sample Files

Posted on December 30th, 2006 at 6:03 am · 1 Comment
Filed in: RSS Downloads   RSS Excel Books   

Sample Files from the Book.

The following sample files were created for use with Creating Spreadsheets and Charts with Microsoft Office Excel 2007: Visual QuickProject Guide. This book covers Excel 2007 for Windows only.

Each of these files represents the project workbook file at the end of a chapter. So if you wanted to follow the steps for Chapter 6 but didn’t want to do Chapters 1-5, you could download the Chapter 5 file and use that as a starting point.

→ 1 Comment • Read 1496 Times
Add to Del.icio.usAdd to Del.icio.us • Technorati ThisTechnorati This • Digg ThisDigg This • Stumble ItStumble it! • Twit ThisTwit This