http://nendeb.jp/?p=563
http://cathval.com/wordpress/3107
とりあえず
prepare("SQL文"); を prepare("SQL文",null);
で対応
//Twenty Fourteen: サイドバー (sidebar.php) <div id="secondary"> //ここから <ul> <li>タグ</li> <?php $tagList = $wpdb->get_results($wpdb->prepare(" SELECT t.term_id,t.name,t.slug,tt.count FROM $wpdb->terms AS t JOIN $wpdb->term_taxonomy AS tt USING(term_id) WHERE tt.taxonomy = 'post_tag' ORDER BY tt.count DESC ",null)); foreach ($tagList as $value):?> <?php $add_style = ''; $add_class = ''; if( is_tag( $value ) ){ $add_class = 'current'; $add_style = 'style="color:#71B6FC;"'; } ?> <li> <a href="/?tag=<?php echo $value->slug; ?>/" <?php echo $add_style;?> class="<?php echo $add_class;?>"> <?php echo $value->name; ?></a> (<?php echo $value->count; ?>)</li> <?php endforeach;?> </ul>