Archive for the ‘Tutorials’ Category

How to display Author info in Wordpress Single Post

Tags: Blogging, Tutorials | No Comments »

If you view a single post of a blog, you will see the author information at the bottom. Here we will see that how we can display such author info in a wordpress blog. That info can be edited in the control panel under Users->Your Profile.

The author’s photo can also display the image using avtars:

<img src="<?php echo get_option('home'); ?>/wp-content/themes/mimbo2/images/<?php the_author_lastname(); ?>.jpg" alt="" />

The author’s name is called like this:

<?php the_author_posts_link('namefl'); ?>

The author’s bio is called like this:

<?php the_author_description(); ?>

The author’s email is called like this:

<a href="mailto:<?php the_author_email(); ?>" title="Email this author">Email this author</a>

That seems like a pretty good start for building your own template themes. Now it’s up to the client to hire some talented writers and hope for the best.

Tags: , ,

Showing category specific wordpress posts

Tags: Blogging, Internet, Tutorials | No Comments »

Displaying category specific posts in a wordpress blog is easy. Inside theme folder the you will find “index.php” and “sidebar.php” templates, you have to put a query_posts functions which refer to specific category ID numbers from your database. Example:

<?php query_posts('showposts=1&cat=4'); ?>

You will need to change them to reflect the ID numbers in your own database. They can be found in your control panel under Manage->Categories.

idnumbers1.gif

Result will be the recent posts from the category no.4

Tags: ,