Risposte nei forum create
-
AutorePost
-
WebmastroPartecipante
fate finta che non abbia postato un bel nulla, sono un somaro.
è stato tutto spostato in basso e va trascinato in alto a destra.
chiedo ancora scusa.
WebmastroPartecipantei tags delle pagine, Bacheca->Gestione->Tags nell’elenco dei tags hai anche il numero delle pagine che contengono quel tag. esportare quelle informazioni.
WebmastroPartecipante<?php /* Template Name: Ascolta */ ?>
<?php get_header(); ?>
<div id=”content”>
<?php if (have_posts(‘page_id=12)); while (have_posts()) : the_post(); ?>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<?php query_posts(‘showposts=10&cat=6’); while (have_posts()) : the_post(); ?>
<?php the_title(); ?><?php the_excerpt(); ?><?php endwhile; ?>
<h2><?php the_title(); ?></h2>
<div class=”post-content”>
<?php the_content(); ?>
</div>
</div>
<?php endwhile; ?>
</div><!–/content –>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
corretto ma rimane l’errore:
Parse error: syntax error, unexpected T_STRING in …/page_asc.php on line 6
[COMUNICAZIONE DI UN MODERATORE: AL PROSSIMO UP, COSA CONTRARIA ALLA POLICY DEL FORUM,SCATTA IL BAN INVECE CHE LA CANCELLAZIONE DELL UP, UP E’ ANCHE TUA EVENTUALE RISPOSTA NON LO SAPEVO, SCUSATE, HO BISOGNO D’AIUTO ETC. SE DEVI COMUNICARE PER QUESTO C’E’ IL MODULO CONTATTI]
WebmastroPartecipante<?php /* Template Name: Ascolta */ ?>
<?php get_header(); ?>
<div id=”content”>
<?php if (have_posts(‘page_id=12)); while (have_posts()) : the_post(); ?>
<div class=”post” id=”post-<?php the_ID(); ?>
<?php query_posts(‘showposts=10&cat=6’); while (have_posts()) : the_post(); ?>
<?php the_title(); ?><?php the_excerpt(); ?><?php endwhile; ?>
<h2><?php the_title(); ?></h2>
<div class=”post-content”>
<?php the_content(); ?>
</div>
</div>
<?php endwhile; ?>
</div><!–/content –>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
mi da il seguente errore:
Parse error: syntax error, unexpected T_STRING in …/page_asc.php on line 6
mi sa che vengono ripetute alcune cose e forse non ne vengono chiuse altre…
WebmastroPartecipanteL’ho ripetuto sino alla noia: DIRE DA’ ERRORRE NON SERVE A NIENTE, si fa tanta fatica a scrivere pure che errore da?
hai ragione, mia mancanza. mi diceva che c’è un errore di sintassi nella riga 11.
allo stesso modo dire di cercare su google premetto, ringrazio chi mi ha risposto, sia ben chiaro!
il fatto è che spesso quando si frequenta una wikik/blog/forum per molto tempo, si da per scontato che chi pone delle domande sia a conoscenza di molte cose.
la soluzione più semplice per me è quella di mandarti per mail un template già pronto o di stamparlo qua sotto, ma credimi ti conviene perdere qualche giorno a capirne il meccanismo altrimenti per ogni minima modifica dovrai dannarti
parole sagge, insegnali a pescare…
guarda, purtroppo il tempo è quello che è tra lavoro e bambini… se mi potessi inviare il file che poi me lo guardo bene. mi faresti un favorone. webmaster at radionk.com
grazie a tutti.
WebmastroPartecipanteok, sto cominciando a capire un po’ di cosette…
però ho difficoltà nell’inserire il codice, nel senso che mi da errore.
il codice in questione è il seguente:
<?php /* Template Name: Ascolta */ ?>
<?php get_header(); ?>
<div id=”content”>
<?php if (have_posts(‘page_id=12)) : while (have_posts()) : the_post(); ?>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<h2><?php the_title(); ?></h2>
<div class=”post-content”>
<?php the_content(‘<p class=”serif”>Read the rest of this page »</p>’); ?>
<?php link_pages(‘<p>Pages: ‘, ‘</p>’, ‘number’); ?>
</div>
</div>
<?php endwhile; endif; ?>
</div><!–/content –>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
non è che mi potresti dire dove inserire per bene il codice?
grazie
WebmastroPartecipantevuoi mettere nel tuo template il contenuto di una pagina statica seguito dai tuoi articoli?
<?php query_posts(‘page_id=xx’); while (have_posts()) : the_post(); ?>
<?php the_content(); ?><?php endwhile; ?>
per stampare la pagina dove xx va sostituito con l’id
<?php query_posts(‘showposts=6’); while (have_posts()) : the_post(); ?>
<?php the_title(); ?><?php the_excerpt(); ?><?php endwhile; ?>
showposts=6 mostra i primi 6 articoli di tutte le categoria
showposts=4&cat=3 mostra i 4 articoli della categoria 3
<?php the_title(); ?><?php the_excerpt(); ?> andranno rispettivamente formattati
perfetto, è quello che voglio fare. a questo punto dove metto il codice? vado nella cartella del theme e poi? (dai che ce la faccio…)
anzi, ho cpaito che bisogna andare a modificare il file page.php facendone una copia in page-1.php e poi modificarlo. come faccio poi a far capire che quella determinata pagina deve caricare quel file pagina-1.php?
WebmastroPartecipanteil template per questa pagina lo creo partendo dal template attuale?
chiedo scusa ma l’aspetto puramente “creativo” dal punto di vista del codice pure mi è totalmente oscuro. onestamente mi sono messo qui 4 ore e più leggendo la wiki e onestamente non ci ho capito mezza… sarà un mio limite ma penso che bisogna saperne di PHP prima di mettersi a sperimentare.
purtroppo non riesco a capire da dove partire!
WebmastroPartecipantemi rispondo:
il feed per ogni categoria si fa con: wp-rss2.php?cat=6 dove ovviamente il numero è la categoria.
per URL, andare di server e fare redirect.
ciao
WebmastroPartecipanterovato.org è fatto bene, dov’è possibile avere il template?
wolly, ho capito quello che vuoi dire, ovviamente fare una colonna per ogni sezione potrebbe essere interessante… la mia osservazione è dettata del fatto che ho visto diverse richieste e spesso senza una risposta.
non voglio essere polemico, sia ben chiaro!!! sono da poco passato a WP e sto cercando di avere maggiori informazioni possibile per avere i migliori risultato.
vabbè, speriamo di trovare qualche esempio.
grazie mille
-
AutorePost