下面是我的分类。php页面代码。我想点菜ASC
. 我怎样才能做到这一点?
<div class="content">
<?php if ( have_posts() ) : ?>
<h2> <?php single_cat_title(\'\',true); ?> </h2>
<ul class="products">
<?php while ( have_posts() ) : the_post();
?>
<li> <a href="<?php
$url = get_post_meta($post->ID, \'productURL\', true);
if ($url) {
echo "$url";
}
?>" target="_blank">
<?php the_post_thumbnail() ?>
<h3><?php the_title(); ?></h3>
<?php endwhile;
?>
</a></li>
<?php else : ?>
<?php endif; ?></ul>
</div>