Temanın birinde popüler videolar kısmı en çok yorum yapılanlardan oluşuyor. Bunu en çok ziyaret edilenlerden oluşturmak için ne gibi değişiklik gerekiyor? Mevcut kodlar aşağıdaki gibi...

index.php

		<!-- Popüler Videolar -->
		<h1>Popüler Videolar</h1>
		<div class="solBlok">
			<ul class="solVideoListe">
				<?php
				$sayi = get_option('bvsy_populer');
				if ($sayi == ''){
					$sayi = 4;
				}
				echo populerVideolar($sayi);
				?>
			</ul>
			<div class="clear"></div>
		</div>
		<!--#Popüler Videolar -->
functions.php

## POPÜLER VİDEOLAR ##
function populerVideolar($sayi=4){

	global $wpdb;
	$posts = $wpdb->get_results("SELECT comment_count, ID, post_title FROM $wpdb->posts ORDER BY comment_count DESC LIMIT 0, $sayi");
	foreach ($posts as $post) {
		setup_postdata($post);
		$title = $post->post_title;
		$resim = get_post_meta($post->ID, "resim", true);
		if (empty($resim)){
			$resim = get_option('home')."/wp-content/themes/bvsy/images/resimyok.jpg";
		}
		$sure = get_post_meta($post->ID, "sure", true);
		$count = $post->comment_count;
		if ($count != 0) {
			$popular .= '<li>';
			$popular .= '
								<a href="'.get_permalink($post->ID).'" rel="bookmark" title="'.$title.'">
									<img src="'.$resim.'" alt="'.$title.'" />
									<span class="vlPlay">Videoyu Oynat</span>
									<span class="vlBaslik">'.$title.'</span>
									<span class="vlSure">'.$sure.'</span>
								</a>
							';
			$popular .= '</li>
			';
		}
	}
	return $popular;
	
}