Custom fiels help for page
-
hello
i create this code (see below) to make a listing of lastest 10 post of category 3 with an icon who appear before title page.
Each icon are different and the image url is add on the custom field of each post<<div class=”box_cont”>
<?php
$postslist = get_posts(‘category=3&numberposts=10&order=DESC&orderby=post_date’);
foreach ($postslist as $post) :
setup_postdata($post);?>
<?php $image = get_post_meta($post->ID, ‘icone’, $single =true); ?><div class=”post_bonus”> /*****bloc who display title post ***/
a href=”<?php the_permalink(); ?>” id=”post-<?php the_ID(); ?>”><?php the_title(); ?>
</div>
<div class=”logo_bonus”> /*****bloc who display an icon before each link***/
a href=”<?php the_permalink(); ?>” id=”post-<?php the_ID(); ?>”><img border=”0″ src=”<?php echo $image; ?>”> </div>
<?php endforeach; ?>This code work very well, but now i would love the same result but for my pages
[icon1] title page1
[icon2] title page2
[icon3] title page3but not find……
Cocota
- The topic ‘Custom fiels help for page’ is closed to new replies.