Differenze tra le versioni di "Aiuto:Gestione lingue sidebar/en"

Da FountainPen.
Jump to navigation Jump to search
(Creata pagina con "In our case the choice is to have values for the "<code>target</code>" in the form "<code>something-cat</code>" when pointing to a category and "<code>something-url</code>" wh...")
(Creata pagina con "For the localization the mechanism is to indicate as content of the "<code>target</code>" an intermediate page. To access the content of the target you need to use the namespa...")
Riga 10: Riga 10:
 
In our case the choice is to have values for the "<code>target</code>" in the form "<code>something-cat</code>" when pointing to a category and "<code>something-url</code>" when pointing to a page. Exceptions are the values used for the names "<code>Forum</code>" and "<code>Blog</code>" whose targets are simple external links that are used as they are.  
 
In our case the choice is to have values for the "<code>target</code>" in the form "<code>something-cat</code>" when pointing to a category and "<code>something-url</code>" when pointing to a page. Exceptions are the values used for the names "<code>Forum</code>" and "<code>Blog</code>" whose targets are simple external links that are used as they are.  
  
Per la localizzazione il meccanismo è indicare come contenuto del "<code>bersaglio</code>" una pagina intermedia. Per accedere al contenuto del bersaglio occorre usare il namespace "Mediawiki", ad esempio per il portale storia si è usato il bersaglio "<code>storia-url</code>" e la relativa pagina è [[Mediawiki:storia-url]], il cui contenuto è il nome della pagina intermedia, nel caso "<code>Storia</code>"; questo contenuto porta direttamente alla pagina [[Storia]], dove si è inserito una semplice redirezione al contenuto finale, [[Portale_Storia]]. Per la traduzione in inglese è bastato creare la pagina [[Storia/en]] il cui contenuto è la redirezione alla pagina [[History_portal]], ed il sistema di redirezione automatico al contenuto della propria lingua porterà chi usa la localizzazione inglese su quest'ultima (altrimenti verrà usato il default). Per altre traduzioni basterà ripetere la cosa, ad esempio creando [[Storia/fr]] con dentro la redirezione alla relativa pagina finale con nome in francese.
+
For the localization the mechanism is to indicate as content of the "<code>target</code>" an intermediate page. To access the content of the target you need to use the namespace "Mediawiki", for example for the portal history was used the target "<code>storia-url</code>" and its page is [[Mediawiki:storia-url]], whose content is the name of the intermediate page, in the case of "<code>Storia</code>", this content leads directly to the page [[Storia]], where you entered a simple redirection to the final content, [[Portale_Storia]]. For the English translation it was enough to create the page [[Storia/en]] whose content is the redirection to the page [[History_portal]], and the system of automatic redirection to the content of your language will bring who uses the English localization on it (otherwise the default will be used). For other translations it will be enough to repeat the thing, for example by creating [[Storia/fr]] with the redirection inside to the relative final page with name in French.
  
 
Il campo "<code>nome</code>" indica invece il testo che comparirà nella sidebar come nome della pagina, per questo campo esistono una lunga serie di valori predefiniti che sono automaticamente tradotti nelle varie lingue, ad esempio il nome "<code>mainpage</code>" diventa automaticamente "Pagina principale" in italiano, "Main Page" in inglese, e così via. Se però si indica un "<code>nome</code>" che non ha un valore predefinito verrà usato direttamente quello come testo che compare nella sidebar. Ma se ne può assegnare uno a piacere semplicemente editando la pagina corrispondente nel namespace "Mediawiki" e mettere le traduzioni dello stesso nelle traduzioni delle suddetta pagina. Riprendendo l'esempio precedente, per il portale storia si è usato come nome "<code>storia</code>" e si è creato il relativo contenuto nella pagina [[MediaWiki:storia]], inserendovi semplicemente il nome "<code>storia</code>" che è quanto compare in italiano. Per le altre lingue basta inserire il nome tradotto nella pagina di traduzione, ad esempio per l'inglese è stato sufficiente creare la pagina [[MediaWiki:Storia/en]] con contenuto "<code>history</code>". La cosa può essere ripetuta in maniera analoga con ogni altra lingua ([[MediaWiki:Storia/fr]], ecc.).
 
Il campo "<code>nome</code>" indica invece il testo che comparirà nella sidebar come nome della pagina, per questo campo esistono una lunga serie di valori predefiniti che sono automaticamente tradotti nelle varie lingue, ad esempio il nome "<code>mainpage</code>" diventa automaticamente "Pagina principale" in italiano, "Main Page" in inglese, e così via. Se però si indica un "<code>nome</code>" che non ha un valore predefinito verrà usato direttamente quello come testo che compare nella sidebar. Ma se ne può assegnare uno a piacere semplicemente editando la pagina corrispondente nel namespace "Mediawiki" e mettere le traduzioni dello stesso nelle traduzioni delle suddetta pagina. Riprendendo l'esempio precedente, per il portale storia si è usato come nome "<code>storia</code>" e si è creato il relativo contenuto nella pagina [[MediaWiki:storia]], inserendovi semplicemente il nome "<code>storia</code>" che è quanto compare in italiano. Per le altre lingue basta inserire il nome tradotto nella pagina di traduzione, ad esempio per l'inglese è stato sufficiente creare la pagina [[MediaWiki:Storia/en]] con contenuto "<code>history</code>". La cosa può essere ripetuta in maniera analoga con ogni altra lingua ([[MediaWiki:Storia/fr]], ecc.).

Versione delle 22:40, 19 dic 2018

The content management of the sidebar is obtained by editing the Mediawiki:Sidebar pages, the operation is reserved for administrators. The content of this page is in the form:

* header
** target|name

the syntax and content management is very twisted, for those interested please refer to the documentation page of Mediawiki, here we will put only essential information.

In our case the choice is to have values for the "target" in the form "something-cat" when pointing to a category and "something-url" when pointing to a page. Exceptions are the values used for the names "Forum" and "Blog" whose targets are simple external links that are used as they are.

For the localization the mechanism is to indicate as content of the "target" an intermediate page. To access the content of the target you need to use the namespace "Mediawiki", for example for the portal history was used the target "storia-url" and its page is Mediawiki:storia-url, whose content is the name of the intermediate page, in the case of "Storia", this content leads directly to the page Storia, where you entered a simple redirection to the final content, Portale_Storia. For the English translation it was enough to create the page Storia/en whose content is the redirection to the page History_portal, and the system of automatic redirection to the content of your language will bring who uses the English localization on it (otherwise the default will be used). For other translations it will be enough to repeat the thing, for example by creating Storia/fr with the redirection inside to the relative final page with name in French.

Il campo "nome" indica invece il testo che comparirà nella sidebar come nome della pagina, per questo campo esistono una lunga serie di valori predefiniti che sono automaticamente tradotti nelle varie lingue, ad esempio il nome "mainpage" diventa automaticamente "Pagina principale" in italiano, "Main Page" in inglese, e così via. Se però si indica un "nome" che non ha un valore predefinito verrà usato direttamente quello come testo che compare nella sidebar. Ma se ne può assegnare uno a piacere semplicemente editando la pagina corrispondente nel namespace "Mediawiki" e mettere le traduzioni dello stesso nelle traduzioni delle suddetta pagina. Riprendendo l'esempio precedente, per il portale storia si è usato come nome "storia" e si è creato il relativo contenuto nella pagina MediaWiki:storia, inserendovi semplicemente il nome "storia" che è quanto compare in italiano. Per le altre lingue basta inserire il nome tradotto nella pagina di traduzione, ad esempio per l'inglese è stato sufficiente creare la pagina MediaWiki:Storia/en con contenuto "history". La cosa può essere ripetuta in maniera analoga con ogni altra lingua (MediaWiki:Storia/fr, ecc.).