Change Category Sort Order

It is strange that there is no option to reverse the display order of the posts on the category page, when we select a category the list is the same as a blog, in descending order newest to oldest.

That is great for a news or magazine website, but what if we wanted to display a series of our posts in ascending order, for a tutorail with the oldest part one first?

Continue reading

Changing Background at Night

We have been looking at changing the body background on a theme based on hour, day, month, or season, in this example we will find out how to change the background in the evening.

We are using a Twenty Ten child theme to do this, so what do we need, we are using two horizontal repeat .png images 1087 wide * 1120 high, one for day and one for the night, if we whanted a different set of images, for any of the other methods we would change the quantities, names and code values to suit.

Continue reading

Facebook Template Beta 2

It has been two weeks since the Beta 1 was released for testing, after feedback we have made a number of changes.

The main topics in this section are still relevant but with a few changes, the major changes are the tabbed admin bar and the way we will create the content, using custom posts, if you have beta 1 then you must de-activate the old plugin first.

Continue reading

Tabbed Options Page

We were searching for code to create a tabbed admin page for our WordPress to facebook Plugin, and we found a very nice website with the code we needed, the website is recommended as one to visit.

It took a while to get a handle on the code as there was no downloadable example, so we have combined two of the One Design posts from the website to create a working example.

Continue reading

Twenty Ten Sidebar Menu Styling

WordPress 3 and the default twenty ten theme are a great base for a stand alone website, easy to work with and with a little knowledge you can make your website theme quite unique.

The default WordPress theme has a sidebar menu but this is hard to style, we tried a lot of different ways to style the menu, in conclusion we have taken the menu above the sidebars into a template part.

Continue reading

Add RSS Icons to Twenty Ten

This post is inspired by a post in the WordPress support themes forum, the question was about there being no RSS icon on the twenty ten theme.

There are two RSS feeds you can offer from your website, posts and comments, so this tutorial will deal with both, another consideration was to open the link in a new tab.

Continue reading

Twenty Ten Alternate Sidebar

The Twenty Ten default theme comes with Primary and Secondary right sidebars, but they are stacked one above the other, you might be wondering why.

At a guess I would say it gives someone new to WordPress the ability to add widgets to the secondary sidebar without losing the built in widgets on the primary sidebar, we are going to use the secondary sidebar for a template page.

Continue reading

Pagenavi Footer Menu and Credits

The tenth and last in this series of tutorials is adding three footer elements, page navigation using ‘wp pagenavi’, a third menu bottom of the footer, and a little editable template part to give us credit for creating the theme.

If we follow the steps in this tutorial we will be able to add numeric page navigation to our WordPress theme, a footer menu bar and credit text after the footer.

We will need to do the following steps, add conditional code to display the ‘wp pagenavi’, add a new menu location and the footer credit text, we will do this with template parts and styling in the style.css.

Continue reading

Main Page

The ninth in this series of tutorials is adding a main template page that will display selected posts by category, using the page and category slugs, order the posts acending and add a custom post header.

If we follow the steps in this tutorial we will be able to add our new template page to our WordPress theme, with conditional posts based on the category and page slug ordered asc and a nice post header section.

We will need to do the following steps, create the template page, and add styles, code to return the posts from WordPress and the post header from the options page using the WordPress call get_option().

Continue reading