Visualizzazione 2 filoni di risposte
Visualizzazione 2 filoni di risposte
- Devi essere connesso per rispondere a questo topic.
Email: info@wpitaly.it
Home › Forum › Problemi Vari con WP › Menù con filtri avanzati sulle categorie
Faccio un esempio per chiarire meglio :
immaginiamo un blog di ricette di cucina ciascuna ricetta è un post .
Ogni Post appartiene sia ad una determinata categoria di “portateâ€, antipasto, primo, secondo etc …
sia alla categoria “indice alfabetico†, A, B, C
Quindi ottengo una barra di navigazione con due liste di categorie …
portate :
• Antipasti
• primi
• secondi
• dolci
Indice Alfabetico :
• A
• B
• …
• Z
Devo cercare le portate che appartengono alla categoria “primi†che iniziano per “Fâ€
Attualmente se premo su Primi otterrò l’elenco di tutti i primi e se premo su F di tutte le ricette chie iniziano per F senza distinzione tra Primi o antipasti
come gestire i menù ?
Non banalmente, occorre scrivere delle funzioni che permettano di elencare menu a discesa con i due gruppi di categoria, e selezionando le due (prevedendo anche di non selezionare uno dei due) fornire un elenco filtrato secondo i due paramentri. Non vi sono funzioni di WP che facciano questa cosa automaticamente… tutto da scrivere a manina, quindi dipende dalle tue capacità e conoscenze di PHP
purtroppo scarse
… può essere una buona occasione per cimentarsi in qualcosa di piu’ complesso che non siano modifiche o accrocchi a codice di altri … ma non saprei da che parte iniziare … ;(
WPItaly - Copyright Creative Commons: CC BY-NC-SA 4.0