rhammill
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Change Profile everytime loginCypher – cool fix. Thanks. I was wondering the same thing. However, macmanx has some great points, so I haven’t decided whether I want to change it just yet.
Was the default behavior changed in 1.5? I didn’t install a hack on my site, but you have to login to post comments (which is fine with me, and the ways I’d like it). Just wondering. Thanks again,
Randy
Forum: Fixing WordPress
In reply to: Sort by date, then alphaAs I discovered … although the MySQL reference says the date function extracts only the date and not the time.
Forum: Fixing WordPress
In reply to: Sort by date, then alphaBy day. For example, what if you wanted to make a list of people’s birthdays. The date is important, but not the specific time, and it would be easier to go through a list alphabetically.
I started with the alphabatizing posts script and modified that to look like this:
<?php
// we add this, to show all posts in our
// Glossary sorted alphabetically
if (is_category(‘Glossary’))
{
$posts = query_posts($query_string .
‘&orderby=date&orderby=title&order=asc&posts_per_page=-1’);
}
// here comes The Loop!
if (have_posts()) : while (have_posts()) : the_post(); ?>***********
This just ends up alphabatizing it. If I comment out the &orderby=title then it sorts by date and accepts the ascending command.
I also tried &orderby=year&orderby=month&orderby=day, but I’m not even sure if those are recognized terms. It didn’t give me an error though.
Thanks,
Randy