只是要總結: 這是如何滑塊應該看起來像 - >http://luiszuno.com/themes/wp-dokedoke/work/porttitor/(原始演示) ,當我添加圖像從媒體到工作去內容,而不是像這樣的滑塊 - >http://netsurf.ir/work/project-2(網址是波斯語) 工作滑塊:(WordPress的)圖像工作的附件,但沒有出現在滑塊
<?php
/*
*
* Retrieve and displays all images
*
*/
$args = array(
'post_type' => 'attachment',
'numberposts' => -1,
'post_status' => null,
'post_parent' => $post->ID,
'post_mime_type' => 'image',
'order' => 'ASC'
);
$attachments = get_posts($args);
?>
<div id="project-gallery"><!-- swipper -->
<div class="gallery-container">
<div class="swiper-container clearfix">
<div class="swiper-wrapper clearfix">
<!-- Images -->
<?php if ($attachments) : ?>
<?php
foreach ($attachments as $attachment) :
$this_image = aq_resize($attachment->guid, 672);
?>
<div class="swiper-slide"> <img src="<?php echo $this_image ?>" alt="<?php echo $attachment->guid ?>"> </div>
<?php endforeach ?>
<?php endif ?>
<!-- ENDS images -->
</div>
</div>
</div>
<!-- ENDS swipper -->
我的工作文字:
<a href="somewhere/03.jpg(cant post more than 2links)"><img class="alignnone size-full wp-image-41" src="http://netsurf.ir/wp-content/uploads/03.jpg" alt="03" width="672" height="400" /></a> <img class="alignnone size-full wp-image-42" src="somewhere/04.jpg" alt="04" width="672" height="400" />