</h2> <small><?php the_time('j F Y'); ?> <!-- par <?php the_author(); ?> --></small> <div class="entry"> <?php if (the_tags) { } ?> <span style="float:left; margin-right: 10px; margin-bottom: 10px"><?php if ($image_path) { thumbnail_img($image_path, 250); } ?> </span> <?php the_content('Lire le reste de cet article »'); ?> </div> <p class="postmetadata"><?php the_tags('Mots-clefs : ', ', ', '<br />'); ?> Publié dans <?php the_category(', '); ?> | <?php edit_post_link('Modifier', '', ' | ');
while (have_posts()) { the_post(); ?> <div class="post-r w360"> <a href="<?php the_permalink(); ?> " rel="bookmark" title="<?php the_title(); ?> "> <span><img src="<?php echo get_bloginfo("template_url"); ?> /timthumb.php?src=<?php echo thumbnail_img(); ?> &h=80&w=100&q=100&zc=1&ct=1&a=t"/></span> <h3><?php the_title(); ?> </h3> <p class="tip"><?php echo mb_strimwidth(strip_tags(apply_filters('the_content', $post->post_content)), 0, 58, "..."); ?> </p> </a> </div> <?php $i++; }
?> " rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?> "> <?php if ($counter == 0) { $w = 320; $h = 250; } else { $w = 155; $h = 80; } ?> <?php thumbnail_img($image_path, $w, $h, "post_image"); ?> <h2><?php the_title(); ?> </h2> </a> <h3><?php the_time('j M Y'); ?> , par <?php the_author(); ?> </h3> <?php }
$my_query->the_post(); ?> <?php $image_path = get_post_meta($post->ID, 'image', $single = true); ?> <li> <div class="spy-thumb"> <a href="<?php the_permalink(); ?> " title="Permanent Link to <?php the_title(); ?> "> <?php thumbnail_img($image_path, 75, 45); ?> </a> </div> <h2><a href="<?php the_permalink(); ?> " title="<?php the_title(); ?> "><?php the_title(); ?> </a></h2> <div class="auth"> Posted by <?php the_author();
function most_commmented($time, $limit) { global $wpdb, $post; $output = '<ul class="hot-in">'; $most_viewed = $wpdb->get_results("SELECT DISTINCT {$wpdb->posts}.* FROM {$wpdb->posts} WHERE post_date > date_sub( now(), interval {$time} day ) AND post_type ='post' AND post_status = 'publish' AND post_password = '' ORDER BY comment_count DESC LIMIT {$limit}"); if ($most_viewed) { $num = 1; foreach ($most_viewed as $post) { $img = '<img src="' . get_bloginfo("template_url") . '/timthumb.php?src=' . thumbnail_img() . '&h=80&w=96&q=100&zc=1&ct=1&a=t"/>'; $output .= '<li><a href="' . get_permalink($post->ID) . '" rel="bookmark" title="' . $post->post_title . '" target="_blank">'; $output .= '<div class="in-img">' . $img . '<span>' . $num . "</span></div>"; $output .= '<div class="in-cont"><h2>' . $post->post_title . '</h2><span>replies: ' . $post->comment_count . "+</sapn></div>"; $output .= '</a></li>'; $num++; } $output .= "</ul>"; echo $output; } }