Post di determinata categoria
-
Buonasera ho trovato online questo script
[COLOR=#0000BB][FONT=Consolas][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php $myposts [/COLOR][/FONT][/FONT][/COLOR][COLOR=#007700][FONT=Consolas][FONT=monospace][COLOR=#666666]=[/COLOR][/FONT][/FONT][/COLOR][COLOR=#0000BB][FONT=Consolas][FONT=monospace][COLOR=black]get_posts[/COLOR][/FONT][/FONT][/COLOR][COLOR=#007700][FONT=Consolas][FONT=monospace][COLOR=#666666]([/COLOR][/FONT][/FONT][/COLOR][COLOR=#DD0000][FONT=Consolas][FONT=monospace][COLOR=blue]'numberposts=5&category=3'[/COLOR][/FONT][/FONT][/COLOR][COLOR=#007700][FONT=Consolas][FONT=monospace][COLOR=#666666]);[/COLOR][/FONT][/FONT][/COLOR] [COLOR=#007700][FONT=monospace][COLOR=#006699][B]foreach[/B][/COLOR][COLOR=#666666]([/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=black]$myposts [/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#006699][B]as[/B][/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=black]$post[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666])[/COLOR][COLOR=#666666]:[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][COLOR=black] [/COLOR][/FONT][/COLOR][COLOR=#000000][FONT=monospace]<a href="[/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php the_permalink[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666]();[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][/FONT][/COLOR][COLOR=#000000][FONT=monospace]" rel="bookmark" title="[/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php the_title[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666]();[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][/FONT][/COLOR][COLOR=#000000][FONT=monospace]">[/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php the_title[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666]();[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][/FONT][/COLOR][COLOR=#000000][FONT=monospace][COLOR=#006699][B]</a>[/B][/COLOR] [/FONT][/COLOR][COLOR=black] [/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php setup_postdata[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666]([/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=black]$post[/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=#666666]);[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]<?[/COLOR][COLOR=black]php [/COLOR][/FONT][/COLOR][COLOR=#007700][FONT=monospace][COLOR=black]endforeach[/COLOR][COLOR=#666666];[/COLOR][/FONT][/COLOR][COLOR=#0000BB][FONT=monospace][COLOR=#666666]?>[/COLOR][/FONT][/COLOR]Lo script estrapola i post di una determinata categoria, io vorrei che questo script mi estrapolasse anche le thumb con rispettivo link al post e porzione di testo lunga quanto io desidero.
Avete qualche consiglio?
Un grazie anticipato
Ciao! Sembra che tu sia interessato a questa conversazione, ma non hai ancora un account.
Stanco di dover scorrere gli stessi post a ogni visita? Quando registri un account, tornerai sempre esattamente dove eri rimasto e potrai scegliere di essere avvisato delle nuove risposte (tramite email o notifica push). Potrai anche salvare segnalibri e votare i post per mostrare il tuo apprezzamento agli altri membri della comunità.
Con il tuo contributo, questo post potrebbe essere ancora migliore 💗
Registrati Accedi