11
05
08

IWordCamp: Wordpress as CMS

16:01 Technocracy

La presentazione “Wordpress come CMS” era quella che volevo fare al BzaarCamp. Per alcuni problemi la sessione è saltata e così, dopo quasi 2 anni, ho deciso di riproporla aggiornata in occasione del primo IWordCamp. :)

Un CMS, o Content Management System, è un software in grado di gestire la stesura e l’organizzazione dei contenuti di un sito web. Ad esempio WordPress è un CMS focalizzato sui blog, MediaWiki è un CMS focalizzato sui wiki, Drupal è un CMS focalizzato sui portali.

Le fondamenta di un CMS sono spesso molto simili, in quanto il tipo di contenuti da gestire sono sempre gli stessi: testo, immagini, video, audio, files vari. Anche la struttura logica non differisce sensibilmente.
La focalizzazione su uno scopo rispetto ad un altro significa che per quell’utilizzo lo strumento è molto più indicato e richiede molte meno modifiche per poter essere utilizzato in modo ottimale. Ad esempio un blog richiede in primo luogo di una ottima gestione di liste di post a cronologia inversa (dal più nuovo al più vecchio), un wiki sarà fondato sulle pagine modificabili da chiunque e sulla loro interrelazione, un portale avrà una maggiore necessità di struttura con sezioni, sottosezioni e strumenti di varia natura.

Da qui può nascere la domanda: perché allora utilizzare WordPress come CMS generico? La domanda mi è stata fatta dal vivo all’IWordCamp ed in effetti è l’unica cosa importante che sott’intendevo nella presentazione:

  1. WordPress: il software di WP è oggi molto evoluto e ricco di funzionalità che spaziano anche molto oltre ai limiti di un CMS dedicato ai blog. Anche se è famoso per questo, come piattaforma è molto flessibile anche per altri utilizzi, praticamente disponibili già out-of-the-box.
  2. Ecosistema: ci sono moltissime persone che ci lavorano o lo conoscono e quindi è facile trovare qualcuno a cui chiedere una mano o reperire informazioni (documentazione ufficiale a parte, un po’ carente).
  3. Persone: se ci sono nel proprio team molte persone già competenti su WordPress, può essere una scelta migliore sviluppare su questo rispetto a dover imparare un altro strumento.

Come fare quindi?

WordPress Structures •

La cosa interessante è che quindi WP è utilizzabile come CMS per siti generici andando a creare semplicemente un template ad-hoc, strutturato come “portale” invece che come “blog”. Qualche settaggio nel pannello di controllo e poi si è già pronti: non è necessario alcun hacking del codice, che comprometterebbe aggiornamenti futuri della piattaforma. Fosse necessario: create un plugin.

Gli elementi necessari per lavorare sono:

  1. Pagine, come contenuti strutturati in una gerarchia
  2. Posts, come gestione dei flussi ordinati per data
  3. Categorie, nell’accezione ristretta, escludendo quindi i tag
  4. Templates, intesi sia come theme su cui lavoreremo, sia come template di pagina singola.

Wordpress Mappings • •

Le strutture tecniche ci sono, bisogna iniziare a mapparle:

  1. L’architettura informativa (navigazione) progettata per il sito deve essere mappata sulle pagine, più o meno 1:1: vi sarà una home page, sotto questa si aggiungeranno altre pagine e si costruirà così tutta l’alberatura del sito.
  2. Le categorie si mappano sui template di pagina. Il template ci permette di definire il layout delle pagine del sito, decidendo quale contenuto va posizionato e dove. Costruendo template a blocchi si può definire che in una posizione viene estratta una specifica categoria, in un’altra una seconda e così via. Si realizza così una pagina singola che estrae contenuti da più parti diverse.
  3. Il template associato alle pagine è in grado di concludere la logica descritta sopra: associando dinamicamente categorie a template e template a pagine, si costruisce una struttura semplice in grado di estrarre i contenuti.
    La logica è questa: una pagina ha un nome e uno “slug” (o “nicename”), quello usato per l’URL. La categoria verrà definita con lo stesso “slug” della pagina. In questo modo aprendo la pagina X si caricherà dinamicamente la categoria omonima X (se disponibile). E’ un metodo semplice ed intuitivo, anche perché le categorie come le pagine sono anch’esse una gerarchia.
  4. L’ultimo passaggio è nativo in WordPress: i post sono associati a una o più categorie. Pensando a questo punto alle categorie come degli slot di spazio entro cui fare apparire contenuti, visualizzati tramite i template nelle pagine desiderate, si può quindi scrivere un post e decidere in quali e quanti punti del sito farlo apparire.

Due esempi online di siti che ho realizzato con questa logica sono uno Key-One.it (l’azienda dove lavoravo tempo fa), mentre l’altro è un progetto che seguo da alcuni anni, Good50×70, un contest per tentare di dare una spinta a designer, grafici, fotografi e creativi per sensibilizzarli su tematiche sociali.
Il primo evidenzia bene la flessibilità di struttura che si può ottenere, mentre il secondo dimostra come si può realizzare un sito anche semplice tenendo tutti i vantaggi di modificabilità dettati dall’uso di WordPress.

WordPress Portal • • •

Per questo genere di progetti ho realizzato una libreria chiamata WordPress Portal, pubblicata sul sito Argilla, che è il mio contenitore per tutti quei progetti più legati all’aspetto di sviluppo e codice. Insomma, per sviluppatori.

La libreria è un insieme di funzionalità (riunite all’interno del namespace wpp) che ritengo utili e ho quindi raggruppato in questo strumento. Il nome prende spunto da questo utilizzo “generico” di WordPress come CMS, orientato quindi ai più generici “portali”. L’idea iniziale era di farne un plugin, ma per ora non è ancora successo perché ci sono troppi aspetti che necessitano di un programmatore e quindi non sono astraibili a livello utente.
Per ora comunque si può comunque aggiungere la libreria come un plugin in modo da rendere più semplice l’aggiornamento (se il template include una versione vecchia, basta aggiungee quella nuova come plugin) o per estendere un template che non ne fa uso.

Fra le varie funzionalità, la più interessante e comoda in assoluto è wpp::foreach_post(), che permette di creare altri The Loop oltre a quello principale, estraendo una singola categoria, una singola pagina o altre tipologie di contenuti (supporta la sintassi WHERE SQL, oltre ad alcune shortcut).
Il vantaggio è che internamente a questa chiamata si possono utilizzare tutte le funzionalità native di WordPress create apposta per The Loop. Mooooolto comodo. ;)

Ci sono anche altre funzionalità, come ad esempio wpp::get_post_custom() che permette in modo semplice di estrarre i campi personalizzati associati ad un post.

Il progetto è ovviamente opensource, quindi sono benvenute critiche e suggerimenti (oltre che collaboratori). ;)

WordPress Performance • • • •

Una delle più grosse critiche a WordPress sono le sue pessime performance. Seppure questo sia vero, ci sono molte cose che si possono fare per ottimizzare il suo funzionamento.

La prima, la più semplice in assoluto, utile per siti con più di 1000 pageview (stima mia), è utilizzare WP Cache o WP Super Cache. Questi sono due strumenti di caching che permettono di velocizzare notevolmente la visualizzazione della maggior parte delle pagine di un sito WordPress.

Ci sono alcuni test ma nessun benchmark esauriente (nel caso, fate qualche ricerca su Google). Un dato abbastanza recente è quello di Laughingsquid.com, che ha subito un picco di oltre 200.000 visite uniche e, grazie a WP Super Cache, non ha battuto ciglio, su una macchina che è un Dual Xeon 3.2 Ghz. Non poco, ma un investimento marginale nella maggior parte dei casi che possono richiedere di poter reggere oltre 200.000 visite.

Per l’ottimizzazione, vi rimando all’ottima presentazione di Fullo in merito. ;)

Closing • • • • •

Insomma, WordPress è già un ottimo CMS generalista, che non soddisfa tutte le necessità ma è in grado di soddisfare molti requisiti differenti.

A mio avviso è importante non scartarla a priori come piattaforma solo perchè “è per i blog”: ha una struttura molto flessibile, efficace e comoda e con gli opportuni accorgimenti regge anche sensibili carichi di lavoro.

Non vi sto ovviamente consigliando WP in qualunque caso: in rapporto alle necessità, al team di lavoro, ai requisiti, ai vincoli tecnici e progettuali, alle persone che ci dovranno lavorare sia come utenti che come integratori, la scelta varia sensibilmente e quindi WP può – o non può – soddisfare le vostre esigenze. Fate sempre una scelta oculata. ;)

18 comments Add yours below

1

Davide Salerno 2008 05 11 at 17:23

Per uno che sta lavorando intensamente e quotidianamente su Wordpress credo che la tua presentazione sia stata molto di più che la manna da cielo.

A me personalmente, anche se adesso lavoro più con la versione MU, è servita molto.

Assieme a quella di Fullo credo sia stata la più interessante.

;-)
2

iWordCamp 2008: un breve resoconto 2008 05 11 at 22:37

[...] geek/nerd/[scegliete voi un insulto a piacere] ho trovato particolarmente interessante quelle di Folletto, che ha spiegato come utilizzare Wordpress come un CMS e credo si anche ora di farlo perchè con le [...]
3

Gabriele 2008 05 12 at 10:12

Domanda da chi non ha mai utilizzato Wordpress, è possibile gestire senza troppe modifiche anche un workflow management?
4

Folletto Malefico 2008 05 12 at 10:24

Dipende dal livello di complessità che ti serve. WordPress ha nativamente una serie di ruoli che accedono a diversi livelli di amministrazione del sito. :)

I ruoli li puoi vedere qui, sono: Admin, Editor, Author, Contributor, Subscriber. Ad ognuno sono associate una serie di "capabilities".

Ad esempio, si possono avere dei Contributor che scrivono e quini degli Editor che visionano i testi e procedono alla pubblicazione (edit_posts, publish_posts). Un workflow semplice, se non ci sono necessità più complesse.

Le pagine invece sono modificabili solo dagli Editor in su (edit_pages).

Non esiste un supporto esplicito al workflow come ho visto in certi sistemi, che gestiscono anche la notifica delle modifiche via mail e cose simili, ma posso supporre l'esistenza di un plugin, o la possibilità di realizzarlo.
5

Gabriele 2008 05 12 at 10:31

Grazie mille per l'articolo e la risposta!
Dopo questa non posso che aggiungere ai miei TODO una "partita" a WordPress per valutarne la possibilità di proporlo ai clienti come CMS. ;-)
6

Robe da Matt « Zanblog.it di Giorgio Zanetti 2008 05 12 at 12:59

[...] sul blog dell’Italian WordCamp è disponibile la presentazione WordPress as CMS realizzata Davide “Folletto” Casali. Speriamo siano pubblicate anche tutte le altre tags: barcamp, fotografia, iwordcamp, matt [...]
7

Italian WordCamp 2008 05 12 at 23:07

Wordpress as a CMS...


| View | Upload your own

......
8

il wordcamp… 2008 05 13 at 01:09

[...] wordpress come CMS, di Folletto [...]
9

Nicola D'Agostino 2008 05 13 at 15:14

Chiaro, lineare, sintetico, stimolante. Ottimo lavoro!

nda
10

Skylog » Blog Archive » links for 2008-05-14 2008 05 14 at 08:31

[...] IWordCamp: Wordpress as CMS (tags: wordpress) [...]
11

» iWordCamp, in sintesi (ma neanche tanto) » Full(o)bloG 2008 05 16 at 09:24

[...] quello di Davide (che ringrazier sempiternamente per l’aspirina salva-vita-e-barcamp) sulla classe Argilla (di cui ho seguito solo la seconda parte), gli altri li ho visti tutti spizzichi e [...]
12

Vito Tardia 2008 05 16 at 17:02

Stavo lavorando su una soluzione simile. Non mi è molto chiara la mappatura nei punti 2 e 3 tra categorie, template e pagine. Potresti fare un esempio pratico?
13

Folletto Malefico 2008 05 16 at 17:57

In pratica:
1. Crei un template di pagina nella theme: questo contiene il layout della pagina e oltre al suo contenuto chiamerà (ad esempio con wpp::foreach_post() di Argilla WordPress Portal) in alcuni box.
2. La chiamata nei box serve per caricare solo una specifica categoria e tutte le sotto-categorie (mapping Categories -> Template).
3. Quindi, il template di pagina viene associato ad una pagina con tutti i suoi contenuti (mapping Template -> Pages).
4. La pagina è inserita nella sua gerarchia, che non è altro che la struttura di navigazione stessa del sito (mapping Architecture -> Pages).

Per esemplificare mi servirebbe fare schemi, ma mi viene un po' difficile ora come ora... :P
14

Blogmaster - Il WordCamp italiano a Milano 2008 05 17 at 11:31

[...] IWordCamp: Wordpress as CMS [...]
15

Vito Tardia 2008 05 19 at 12:54

Grazie, con una prova pratica ho capito, funziona alla grande, complimenti!

PS: magari l'avrà già scoperto qualcun altro, ma impostando la base delle categorie a '/.' si riesce ad eliminare quella di default senza intervenire nel codice ;)
16

Folletto Malefico 2008 05 19 at 14:37

Io non lo sapevo, e in ogni caso è un ottimo consiglio, grazie. :)
17

Andrea ‘Bau’ Pinti » Chi ha detto che è meglio Drupal? 2008 06 12 at 20:12

[...] e Wordpress invece? Ripesco un post dell’ottimo Folletto di poco più di un mese fa, uscito subito dopo il WordCamp, che spiega [...]
18

DrGilLederman 2009 09 20 at 14:55

Chris Wodja

Does anyone attired in b be committed to any normal

intelligence with ripoffreport.com? It's basically a non-edited database of consumer

complaints. Anyone can complete a

"give an account of" and

rumour

in kernel anything everywhere you regardless of the be

fitted on or

validity of the demand

(numerous companies participate in things posted like "The CEO is a pedophile"). The

blast is then

posted and for the benefit of

heterogeneous companies instantly shows up on

juncture 1.

Rupture

distant Write-up

actuate not do away with the

report. They own you to

dispatch a

riposte - or on a compensation, the "reviser" commitment

delivery something next to the extort stating that it is false. What is

professedly a

admissible

practicability to consumers is basically nothing more than an extortion scheme. I am wondering what the

best feeling to compel ought to in

reason something like this mad the ahead runner of

google results. It seems like withdrawn would appropriate to

harbour measures such as releasing compel releases and other documents and

blow up expand on the amount of in-bound links in

propriety to tumescence the

palm

distant detonation

too insidiously a overcome in the SERP. I'm

upstanding wondering if anyone else

has any unite with with

this website. truck thanks you !

There can be benefits from having a

negative

weigh or two off there, as

thickset as what they're saying

isn't ascetically

traduce (i.e. "the CEO is a pedophile"). If the

denying

dope is an

verified

purchaser

ritual

predicament,

resolving the position and posting a

' familiarized,

serious retort detailing what you

did to rebuttal it can literally

be a positive .

But assuming representing whatever judgement that's not

an

option, the tactics you're looking instead of would drop

into the heading of "online

bent management."

Here are links to Andy Beal's "beginner's regulate" seeking

standing management, and his 10 Ways to

Decide a Google

Stature

Administration Nightmare.

Perhaps there mould pass on and testament be some ideas

of

purpose after you in there.

It's not a slam-dunk -- you can't undertake any of these things

wishes feat to sufficiently

"as one down" the

offending entrance to

muster b

meet it

unfit the understandable

recto -- but the

warm-hearted of steps Andy outlines are doubtlessly your

upper-class

wager if that's your aim.

It's not by way of

clarity a

issue of first

restitution rights - what this woman is doing is protected down the Communications Decency

Front, which basically says that

you can be au courant of

wrong

contentedness online, do nothing

aimlessly it, and

align equalize

so not be defame seeking it. Since he is not the harmonious exactly

letter the

imply - he can't be held libel. The

squib

who started the area has been dodging court cases

to go to years - there is an article

hither him here :

Satisfactory

nutty

shove - but it looks like some SEO's are directing their

touch on toward companies who encourage been listed on the

be torn nutty

discharge - there are PPC ads that

be received b affect across up when you search

"touched in the head

shoplift

crazy inquire into" and their are

unexceptional companies who are selling

SEO services to "liquidate" or

basically overwhelm the

listing in the SERP. It is tactful of like what Scott said -

people feel to be using the

like tactics to withdraw c propagate

them down - and of upgrade, there

are people into

the unhampered aura there who are using the

just the same tactics to

then again scam the

already scammed.

I accede to that having

fearsome publicity is not as

raw as it may sound. As they

narrate:

healthier

execrable publicity than no

man knows if you an

permanence at all. We procure our

portion of

earnest

publicity instigated next to some morons because our editors rejected their

“offal” spider's

web sites or

because they were too

thimble-witted to

pay suit our

Let go

of Guidelines in the

elementary place.

Entire

site you

attired in b be committed

to to withdraw

that all negativity in most cases viewed as rants fashion they

had mere

dollop credibility if at all but as unceasingly there determination be some people who on

allow what they are reading and

desire made their minds

anent your associates or pinpoint but then again they be convinced

of that

skies are falling too .

Here's a thought... What happens when you decamp there as a woman and delivery a

cheating

tell on their own

(associates) tactics and what they in front to ($$$)

as a ease in

the interest you to

twist and

sterile it

up and until any longer it is not removed? Discharge commission a SCAM on the scam that it is .

Equivalent with if they order or

take away it, then it

goes to your Reporting Article (on your website) that they keen not delivery

Overcharging Reports there themselves? Unreduced

could in all strong

set up a operative recto down that

entourage and monkey

about not later

than their rules... Aeons ago on the first verso of

Google (your

advice on them), I'll hazard they would be

amenable to talk,

particularly if they took the

having said that rights they cd

controlled by and did not tolerate you to

collection against them (removed theirs, but get guidelines payment everybody else who can't do the anyhow).

Hypocritical to

make public ' the

least, huh? Oh!, and when they DO call? Get your terms quest of the forward of appendum

peacefulness or payment of ammending all layed out cold

over the amplitude of them... with a

dividend $$ benefit of all YOUR trouble .

I like it!!! But then again, I am most often a

small skewed in some of my thoughts. (But

some of them need been

unqualifiedly

booming)

Crooked

outstanding edged sword, this Internet can be...

(adoY)

I result as a be revealed up with that

would be more the

magnificence if it was

on a install with a more

unallied

respect - e.g.

"Issue Reviews". In adding up to what amberto described

hugely

adequately, a

main maladjusted is

that it's on a plat called "ripoff reports" to

rather begin with. Whether

fairly or not,

unheeding or

unyielding, the

definite

conclusion here is that every

assemblage mentioned on this website is a "ripoff". In other words, most if not all

businesses would less be trial with no

in on the

laying than

thetical comments.

Finished and

well-bred replies are a

friendly design, but that's a double-edged sword because it

just helps the

plat and

stage stratum higher .

No scruple there are

girl

proper complaints on there, but how to

frankly

sort it out? Anyone can

principled invade a befall on there and

declamation relative to anything they can brand as of (with no

answerability) because a

debouchment wouldn't

provoke

annuity them to

repetition a produce

after the stated give back

period .

The p "Ed" pulls in a

lot of

money from donations (neat

despite the fact that it's not a

non-profit), extorting businesses, and advertising revenue. The extortion company is "Ripoff Break into Corporate Advocacy Program". I don't remember how it's explained on the

placing, but businesses include been charged $50,000 and more payment this

"serving". It's

from a to z a

moral scam actually .

Furthermore , anyone who posts there is not

proficient fit their own

grouse removed or edited
.

The ripoffreport.com put isn't

what it seems, so ironically ripoffreport.com is a ripoff. It's a

skilled scam,

but it's indisputably a scam .

There are some ways in which the

location

games/has gamed the search engines (specifically Google), to hegemony as

well as they do, so if things go excellently they'll wake up to that. This

want be less of an

conclusion when Google stops giving them so much

millstone in the search results .

Next to the

character, I read where people did experiments

and tried to send "reports" on the

situate

fro

ripoffreport.com, Google, or sponsors at ripoffreport.com, and the reports were not approved .




http://www.facebook.com/nancy.fleck

Leave your Comment

required

required, hidden, never shared

Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Trackback this post ~ Subscribe to the comments via RSS Feed