• Moderator t-p

    (@t-p)


    Hi all,
    I use WP default theme.

    My all posts are posted under “uncategorized”

    In the sidebar, when “uncategorized” is clicked, by default full posts are listed by date.

    How can I have them listed alphabetically in titles instead?

    Thanks in advance.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Moderator t-p

    (@t-p)

    Thanks a lot esmi!

    I appreciate your response very much.

    I read that many times.

    I tried the following but it did not do the trick.
    <?php wp_list_categories('show_count=1&orderby=title&order=ASC&title_li=<h2>Categories</h2>'); ?>

    Obviously I am not applying the codex right. Please guide. thanks again.

    <?php query_posts(‘orderby=name&order=ASC’);
    if(have_posts()): while(have_posts()): the_post();
    ?>
    <h2>“><?php the_title?></h2>
    <?php endwhile; else; endif; ?>

    This code will list all posts TITLE in alphabetical order :

    I hope that will help

    <?php query_posts('orderby=name&order=ASC');
    if(have_posts()): while(have_posts()): the_post();
    ?>
    <h2><a href="<?php the_permalink()?>"><?php the_title?></a></h2>
    <?php endwhile; else; endif; ?>

    This code will list all posts TITLE in alphabetical order :

    I hope that will help

    Moderator t-p

    (@t-p)

    Thanks khiangte.

    I tried both and both gives me parse error:

    Parse error: parse error, unexpected ‘;’, expecting ‘:’ in /home/XXX…/html/blog/wp-content/themes/mytheme/sidebar.php on line 100

    ohh my mistake …

    change else

    ;

    to else

    :

    , or you can remove else statement otherwise you want to put some code if there is no post

    else; TO else: , see the difference ,semicolon to colon LOLZ

    Moderator t-p

    (@t-p)

    Thanks khiangte for your help, time and pasient.

    I changed that but no luck.

    Please know that I am trying to modify the existing “uncategorized” item in the sidebar. After all said and done, I would like to be able to click on “uncategorized” and be able to see all content listed with titles only, alphabeticaly instead of now (WP default) which when I click “uncategorized”, full posts are listed by date.

    Thanks esmi and khiangte.

    can you give me a link to your site..

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Archive for the ‘Uncategorized’ in sidebar to display as alphabetized title list’ is closed to new replies.