我可以通过压缩这个来减少查询吗?,我可以减少查询吗?如果可以,我该怎么做?
注:图像大小不同
<div class="art-Block">
<div class="art-Block-tl"></div>
<div class="art-Block-tr"></div>
<div class="art-Block-bl"></div>
<div class="art-Block-br"></div>
<div class="art-Block-tc"></div>
<div class="art-Block-bc"></div>
<div class="art-Block-cl"></div>
<div class="art-Block-cr"></div>
<div class="art-Block-cc"></div>
<div class="art-Block-body">
<div class="index-categorie">Stiri din lumea cinematografiei</div>
<div class="index-linie"></div>
<div id="dbs">
<div class="dbl">
<?php
$recentPosts = new WP_Query();
$recentPosts->query(array(
\'post_type\' => \'stiri\',
\'showposts\' => 1,
\'offset\'=>0,
\'taxonomy\' => \'stire\',
\'stire\' => \'articole-speciale\'
)
);
?>
<?php while ($recentPosts->have_posts()) : $recentPosts->the_post(); ?>
<a href="<?php the_permalink() ?>" title="<?php the_title(); ?>"><?php $excerpt = the_title();echo string_limit_words($excerpt,5);?></a>
<div class="dbli"><a href="<?php the_permalink() ?>"><img src="/scripts/timthumb.php?src=<?php the_field(\'imagine_stire\'); ?>&h=240&w=418&zc=1" alt="<?php the_title(); ?>" title="<?php the_title(); ?>" /></a></div>
<div class="dblc">
<?php $excerpt = get_the_excerpt();echo string_limit_words($excerpt,80);?><a class="detalii" href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__(\'Stire %s\'), the_title_attribute(\'echo=0\')); ?>">...detalii</a>
<?php endwhile; ?>
</div>
<?php
$recentPosts = new WP_Query();
$recentPosts->query(array(
\'post_type\' => \'stiri\',
\'showposts\' => 6,
\'offset\'=>1,
\'taxonomy\' => \'stire\',
\'stire\' => \'articole-speciale\'
)
);
?>
<?php while ($recentPosts->have_posts()) : $recentPosts->the_post(); ?>
<div class="dbls">
<div class="dblsi"><img src="/scripts/timthumb.php?src=<?php the_field(\'imagine_stire\'); ?>&h=40&w=40&zc=1" alt="<?php the_title(); ?>" title="<?php the_title(); ?>" /></div>
<div class="dblst"><a href="<?php the_permalink() ?>"><?php $mytitle = get_the_title(); if ( strlen($mytitle) >60 ) $mytitle = substr($mytitle,0,60); echo $mytitle; ?></a></div>
</div>
<?php endwhile; ?>
</div>
<div class="dbr">
<?php
$recentPosts = new WP_Query();
$recentPosts->query(array(
\'post_type\' => \'stiri\',
\'showposts\' => 5,
\'offset\'=>1,
\'taxonomy\' => \'stire\',
\'stire\' => \'articole-speciale\'
)
);
?>
<?php while ($recentPosts->have_posts()) : $recentPosts->the_post(); ?>
<div class="dbrs">
<div class="dbrsi"><a href="<?php the_permalink() ?>"><img src="/scripts/timthumb.php?src=<?php the_field(\'imagine_stire\'); ?>&h=77&w=218&zc=1" alt="<?php the_title(); ?>" title="<?php the_title(); ?>" /></a></div>
<div class="dbrst"><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></div>
</div>
<?php endwhile; ?>
</div>
<div id="dbm">
<?php
$recentPosts = new WP_Query();
$recentPosts->query(array(
\'post_type\' => \'stiri\',
\'showposts\' => 4,
\'offset\'=>1,
\'taxonomy\' => \'stire\',
\'stire\' => \'articole-speciale\'
)
);
?>
<?php while ($recentPosts->have_posts()) : $recentPosts->the_post(); ?>
<div class="dbmc">
<div class="dbmci"><a href="<?php the_permalink() ?>"><img src="/scripts/timthumb.php?src=<?php the_field(\'imagine_stire\'); ?>&h=77&w=143&zc=1" alt="<?php the_title(); ?>" title="<?php the_title(); ?>" /></a></div>
<div class="dbmct"><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></div>
</div>
<?php endwhile; ?>
</div>
</div>
</div>
</div>