Page 1 of 1

pretty url modulo news

Posted: Mon Mar 12, 2012 7:52 pm
by giapippo
ciao a tutti

ho attivato il mod rewrite con successo nella versione cmsms 1.10.3 - modulo news 2.12.3

ma purtroppo nel modulo news non funziona come vorrei ovvero

ottengo un indirizzo cosi:

http://www.xxxxxxx.com/news/7/56/Agente-di-commercio-ecco-le-caratteristiche-che-lo-contraddistinguono


ma lo vorrei cosi
http://www.xxxxxxxx.com/news/Agente-di-commercio-ecco-le-caratteristiche-che-lo-contraddistinguono

come posso risolvere? grazie mille in anticipo

Re: pretty url modulo news

Posted: Tue Mar 20, 2012 4:09 pm
by protempore
giapippo wrote:ciao a tutti

ho attivato il mod rewrite con successo nella versione cmsms 1.10.3 - modulo news 2.12.3

ma purtroppo nel modulo news non funziona come vorrei ovvero

ottengo un indirizzo cosi:

http://www.xxxxxxx.com/news/7/56/Agente-di-commercio-ecco-le-caratteristiche-che-lo-contraddistinguono


ma lo vorrei cosi
http://www.xxxxxxxx.com/news/Agente-di-commercio-ecco-le-caratteristiche-che-lo-contraddistinguono

come posso risolvere? grazie mille in anticipo
non puoi ottenere quello che vuoi... cmsms ha bisogno di sapere a quale pagina del cms deve andare per visualizzare il dettaglio (nel tuo caso "56") e il modulo News qual è l'ID da visualizzare (nel tuo caso "7")... se li togli non ti funziona più nulla.

Re: pretty url modulo news

Posted: Tue Mar 20, 2012 4:13 pm
by calguy1000
Normally news article titles are not forced to be unique across the system (all modules etc), therefore there is no automatic way of generating urls like you want. However in CMSMS 1.10.x, When editing a news article there is a 'url' field where you can manually type in the url for the news article and it is forced to be unique across the system.

If this url field is empty then the standard 'pretty url' containing the detail page, and the article id will be generated for the detail url.

Addendum:
This is 'another' mechanism of accessing the same data... the routes for news/##/##/some-string are still valid ways to access the news article. Therefore it is very important that you have the canonical url stuff working properly in your templates so that google doesn't think you have duplicated content.