ciao a tutti, prendendo spunto da qui http://forum.html.it/forum/showthrea...readid=2900422 ho impostato una home page accessibile solo alla redazione in cui si vedono gli articoli bozze proprio come se fossero pubblicati. il codice che ho usato è questo
Codice PHP:
<?php query_posts('cat='.$id_categoria[32].'&post_status=draft&showposts='.$n_articoli[32].''); ?> <?php $posts = get_posts('category='.$id_categoria[32].'&post_status=draft&numberposts='.$n_articoli[32].'&offset=0'); foreach ($posts as $post) : start_wp(); ?>
<a style="color: #000;font-weigth:normal; margin-right:25px;" href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
<?php endforeach; ?>
questo però mostra solo gli articoli in bozze, come faccio a far si che mostri anche quelli pubblicati?
già che ci sono faccio un'altra domanda: dall'altra discussione mi sembra di aver capito che il primo query_posts possa essere tolto, è così? posso quindi togliere
è corretto?Codice PHP:
<?php query_posts('cat='.$id_categoria[32].'&post_status=draft&showposts='.$n_articoli[32].''); ?>
grazie a tutti!![]()