Voici le contenu de page "type-portfolio.php"
<div class="portfolio">
<ul class="image-grid">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<li>
<h2><a><?php the_title(); ?></a><h2>
<?php
if ( has_post_thumbnail()) {
$large_image_url = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), 'large');
echo '<a rel="lightbox[uniqueID|filename]" href="' . $large_image_url[0] . '" title="<?php the_title(); ?>' . the_title_attribute('echo=0') . '" >';
echo get_the_post_thumbnail($post->ID, 'portfolio');
echo '</a>';
}
?>
</li>
<div class="clear"></div>
<?php endwhile; else: ?>
<p><?php_e('Sorry, no posts'); ?></p>
<?php endif; ?>
</ul>
</div>
J'ai associé un plugin Lightbox permettant de zoomer sur mes images.
Je pense que la fonction
'posts_per_page' =>-1
est la bonne solution pour afficher toutes mes images (et supprimer cette limitation à 10 images) mais après avoir essayé pendant des heures je n'ai malheureusement pas trouvé comment l'utiliser.
Quelqu'un peut-il m'éclairer ?