← WordPress

Mostrar apenas um ou dois IDs

Lida 1714 vezes

Offline

nandotx 
Membro
Mensagens 1012 Gostos 1
Feedback +9

Troféus totais: 28
Trófeus: (Ver todos)
Apple User Mobile User Windows User Super Combination Combination Topic Starter Poll Voter Level 5 Level 4 Level 3

Neste link podem ver como excluir alguns IDs da lista, mas eu queria um código onde colocasse apenas os IDs que quero mostrar (neste caso seriam apenas 1 ou 2).

Alguém sabe como fazer isso?
Offline

HeM 
Membro
Mensagens 95 Gostos 0
Troféus totais: 24
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Poll Starter Level 4 Level 3 Level 2 Level 1 50 Posts

http://codex.wordpress.org/Template_Tags/wp_list_pages

Citar
In the following example, only Pages with IDs 9, 5, and 23 are included in the list and the heading text has been changed to the word "Poetry", with a heading style of <h2>:

<ul>
  <?php wp_list_pages('include=5,9,23&title_li=<h2>' . __('Poetry') . '</h2>' ); ?>
</ul>
Offline

nandotx 
Membro
Mensagens 1012 Gostos 1
Feedback +9

Troféus totais: 28
Trófeus: (Ver todos)
Apple User Mobile User Windows User Super Combination Combination Topic Starter Poll Voter Level 5 Level 4 Level 3

:obrigado: HeM!