Acciones

Ayuda

Diferencia entre revisiones de «Códigos de edición»

De La Venciclopedia

imported>Lizardkg
Sin resumen de edición
imported>Malin
Sin resumen de edición
Línea 62: Línea 62:
|-
|-
| <nowiki>{{CURRENTDAY2}}</nowiki>
| <nowiki>{{CURRENTDAY2}}</nowiki>
| <code>{{CURRENTDAY2}}</code>
| No funciona en nuestra versión
| '''[MW1.6+]''' Igual que <nowiki>{{CURRENTDAY}}</nowiki>, pero con cero adelante (01 .. 31).
| '''[MW1.6+]''' Igual que <nowiki>{{CURRENTDAY}}</nowiki>, pero con cero adelante (01 .. 31).
|-
|-
Línea 90: Línea 90:
|-
|-
| <nowiki>{{CURRENTHOUR}}</nowiki>
| <nowiki>{{CURRENTHOUR}}</nowiki>
| <code>{{CURRENTHOUR}}</code>
| No funciona en nuestra versión
| Solo la hora actual, sin minutos (00 .. 23).
| Solo la hora actual, sin minutos (00 .. 23).
|-
|-
| <nowiki>{{CURRENTMINUTE}}</nowiki>
| <nowiki>{{CURRENTMINUTE}}</nowiki>
| <code>{{CURRENTMINUTE}}</code>
| No funciona en nuestra versión
| Los minutos actuales (00 .. 59).
| Los minutos actuales (00 .. 59).
|-
|-
| <nowiki>{{CURRENTSECOND}}</nowiki>
| <nowiki>{{CURRENTSECOND}}</nowiki>
| <code>{{CURRENTSECOND}}</code>
| No funciona en nuestra versión
| Los segundos actuales (00 .. 59).
| Los segundos actuales (00 .. 59).
|-
|-
Línea 110: Línea 110:
|-
|-
| <nowiki>{{CURRENTTIMESTAMP}}</nowiki>
| <nowiki>{{CURRENTTIMESTAMP}}</nowiki>
| <code>{{CURRENTTIMESTAMP}}</code>
| No funciona en nuestra versión
| '''[MW1.7+]''' La hora completa según ISO 8601.
| '''[MW1.7+]''' La hora completa según ISO 8601.
|}{{-}}
|}


===Hora local===  
=== Estadísticas ===
La hora depende de la zona horaria local de la wiki (''no'' la zona horria elegida por el usuario en las preferencias). (Todas '''[MW1.8+]''' )
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
! Ejemplo  
! Ejemplo
! Explicación
! Explicación
|-
|-
| <nowiki>{{LOCALDAY}}</nowiki>
| <nowiki>{{NUMBEROFARTICLES}}</nowiki>
| <code>{{LOCALDAY}}</code>
| <code>{{NUMBEROFARTICLES}}</code>
| Displays the local day of the month in numeric form.
| Retorna numero de artículos.
|-
|-
| <nowiki>{{LOCALDAY2}}</nowiki>
| <nowiki>{{NUMBEROFFILES}}</nowiki>
| <code>{{LOCALDAY2}}</code>
| <code>{{NUMBEROFFILES}}</code>
| Same as <nowiki>{{LOCALDAY}}</nowiki>, but with a leading zero (01 .. 31).
| '''[MW1.5+]''' Retorna numero de archivos subidos (filas en la tabla de imagenes).
|-
|}
| <nowiki>{{LOCALDAYNAME}}</nowiki>
| <code>{{LOCALDAYNAME}}</code>
| Name of the day in the language of the project or English.
|-
| <nowiki>{{LOCALDOW}}</nowiki>
| <code>{{LOCALDOW}}</code>
| Same as <nowiki>{{LOCALDAYNAME}}</nowiki>, but as a number (0=Sunday, 1=Monday...).
|-
| <nowiki>{{LOCALMONTH}}</nowiki>
| <code>{{LOCALMONTH}}</code>
| The number 01 .. 12 of the month.
|-
| <nowiki>{{LOCALMONTHABBREV}}</nowiki>
| <code>{{LOCALMONTHABBREV}}</code>
| Same as <nowiki>{{LOCALMONTH}}</nowiki>, but in abbreviated form as Jan .. Dec.
|-
| <nowiki>{{LOCALMONTHNAME}}</nowiki>
| <code>{{LOCALMONTHNAME}}</code>
| Same as <nowiki>{{LOCALMONTH}}</nowiki>, but in named form as January .. December.
|-
| <nowiki>{{LOCALTIME}}</nowiki>
| <code>{{LOCALTIME}}</code>
| The local time (00:00 .. 23:59).
|-
| <nowiki>{{LOCALHOUR}}</nowiki>
| <code>{{LOCALHOUR}}</code>
| The local hour (00 .. 23).
|-
| <nowiki>{{LOCALWEEK}}</nowiki>
| <code>{{LOCALWEEK}}</code>
| Number of the local week (1-53) according to [[w:en:ISO 8601|ISO 8601]] with no leading zero.
|-
| <nowiki>{{LOCALYEAR}}</nowiki>
| <code>{{LOCALYEAR}}</code>
| Returns the local year.
|-
| <nowiki>{{LOCALTIMESTAMP}}</nowiki>
| <code>{{LOCALTIMESTAMP}}</code>
| [[w:en:ISO 8601|ISO 8601]] time stamp.
|}{{-}}
 
*See also the [[ParserFunctions#.23time:|ParserFunction #time:]]
 
=== Statistics ===
Statistics variables give thousands separators unless ":R" for "raw" is added (actually, these versions are parser functions).


=== Títulos y relacionados ===
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
Línea 180: Línea 135:
! Explicación
! Explicación
|-
|-
| <nowiki>{{CURRENTVERSION}}</nowiki>
| <nowiki>{{PAGENAME}}</nowiki>
| <code>{{CURRENTVERSION}}</code>
| <code>{{PAGENAME}}</code>
| '''[MW1.7+]''' {{h:mwg|Version}} [http://mail.wikipedia.org/pipermail/mediawiki-i18n/2006-May/000026.html]
| Nombre de la pagina.
|-
|-
|<nowiki>{{NUMBEROFEDITS}}</nowiki><br /><nowiki>{{NUMBEROFEDITS:R}}</nowiki>
| <nowiki>{{PAGENAMEE}}</nowiki>
| <code>{{NUMBEROFEDITS}}</code><br /><code>{{NUMBEROFEDITS:R}}</code>
| <code>{{PAGENAMEE}}</code>
| '''[MW1.10+ (r21319)]''' Returns the total number of page edits since MediaWiki, the software that runs this site, was installed.
| Nombre de la pagina sin espacios.
|-
|-
| <nowiki>{{NUMBEROFARTICLES}}</nowiki><br /><nowiki>{{NUMBEROFARTICLES:R}}</nowiki>
| <nowiki>{{NAMESPACE}}</nowiki>
| <code>{{NUMBEROFARTICLES}}</code><br /><code>{{NUMBEROFARTICLES:R}}</code>
| <code>{{NAMESPACE}}
| A [[Help:Variable|variable]] which returns the total number of articles on the Wiki.
| Espacio de nombre.
|-
|-
| <nowiki>{{NUMBEROFPAGES}}</nowiki><br /><nowiki>{{NUMBEROFPAGES:R}}</nowiki>
| <nowiki>{{REVISIONID}}</nowiki>
| <code>{{NUMBEROFPAGES}}</code><br /><code>{{NUMBEROFPAGES:R}}</code>
| <code>{{REVISIONID}}</code>
| '''[MW1.7+]''' Returns the total number of pages. [http://mail.wikipedia.org/pipermail/mediawiki-i18n/2006-May/000026.html]
| '''[MW1.5+]''' Numero de edición.
|-
|-
| <nowiki>{{NUMBEROFFILES}}</nowiki><br /><nowiki>{{NUMBEROFFILES:R}}</nowiki>
| <nowiki>{{SITENAME}}</nowiki>
| <code>{{NUMBEROFFILES}}</code><br /><code>{{NUMBEROFFILES:R}}</code>
| <code>{{SITENAME}}</code>
| '''[MW1.5+]''' Returns the number of uploaded files (rows in the image table).
| Nombre del sitio.
|-
|-
| <nowiki>{{NUMBEROFUSERS}}</nowiki><br /><nowiki>{{NUMBEROFUSERS:R}}</nowiki>
| <nowiki>{{SERVER}}</nowiki>
| <code>{{NUMBEROFUSERS}}</code><br /><code>{{NUMBEROFUSERS:R}}</code>
| <small>{{SERVER}}</small>
| '''[MW1.7+]''' Returns the number of registered users (rows in the user table).
| Nombre del servidor.
|-
|-
| <nowiki>{{NUMBEROFADMINS}}</nowiki><br /><nowiki>{{NUMBEROFADMINS:R}}</nowiki>
| <nowiki>{{SCRIPTPATH}}</nowiki>
| <code>{{NUMBEROFADMINS}}</code><br /><code>{{NUMBEROFADMINS:R}}</code>
| <code>{{SCRIPTPATH}}</code>
| '''[MW1.7+]''' Returns the number of administrators (users in the ''sysop'' group).
| '''[MW1.5+]''' Dirección.
|-
|-
| <nowiki>{{PAGESINNAMESPACE}}</nowiki>
| <nowiki>{{SERVERNAME}}</nowiki>
| &#160;{{#if:{{#ifexpr:{{PAGEINNS:0|R}}}}|<font color="red">'''disabled here'''</font>}}
| <code>{{SERVERNAME}}</code>
| Longer alias of PAGESINNS
| '''[MW1.5+]''' Nombre del servidor.
|-
|-
| <nowiki>{{PAGESINNS:ns}}</nowiki><br /><nowiki>{{PAGESINNS:ns:R}}</nowiki>
|}
| <nowiki>{{PAGESINNS:2}}</nowiki>&#160;{{#if:{{#ifexpr:{{PAGEINNS:0|R}}}}||=&#160;<tt>{{PAGESINNS:2}}</tt>}}<br /><nowiki>{{PAGESINNS:2:R}}</nowiki>&#160;{{#if:{{#ifexpr:{{PAGEINNS:0|R}}}}|<br /><font color="red">'''disabled here'''</font>|=&#160;<tt>{{PAGESINNS:2|R}}</tt>}}
| '''[MW1.7+]''' Returns the number of pages in the given namespace. Disabled by default, enable with {{h:mwg|AllowSlowParserFunctions}}.
|}{{-}}
 
=== Page names and related info ===
{{:H:Page_name_variables}}
 
==Parser functions==


:''For details see [[Help:Parser function]].''
==Funciones parser==
 
No funcionan en la posicion de lapagina donde se encuentran sino en el encabezado, y a trves de la pagina, respectivamente (ver abajo):
Not working at the position of the page where the tag is located but on the page header, and throughout the page, respectively (see below):
*DISPLAYTITLE: permite que el titulo del encabezado sea diferente que el nombre de la pagina.
*DISPLAYTITLE: allow the page header to be different from the page name.
*DEFAULTSORT: Impone una manera de clasificar categorías en la pagina por definicion.
*DEFAULTSORT: Sets a default [[Help:Categories#Sort_key|category sort key]] for the page.
=== Espacios de nombres y URLs ===
 
=== Namespaces and URLs ===
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
Línea 236: Línea 181:
| <nowiki>{{ns:}}</nowiki>
| <nowiki>{{ns:}}</nowiki>
| <nowiki>{{ns:4}}</nowiki> = <code>{{ns:4}}</code><br /><nowiki>{{ns:project}}</nowiki> = <code>{{ns:project}}</code>
| <nowiki>{{ns:4}}</nowiki> = <code>{{ns:4}}</code><br /><nowiki>{{ns:project}}</nowiki> = <code>{{ns:project}}</code>
| Returns the name of a given [[Help:Namespace|namespace number]].
| Nombre del numero de un espacio de nombre.
|-
| <nowiki>{{localurl:x y @}}</nowiki><br /><nowiki>{{localurle:x y @}}</nowiki><br /><nowiki>{{localurl:a|b=c}}</nowiki><br /><nowiki>{{localurl:Wikipedia:Category}}</nowiki>
| <code>{{localurl:x y @}}<br />{{localurle:x y @}}<br />{{localurl:a|b=c}}<br />{{localurl:Wikipedia:Category}}</code>
| Returns the local URL of a page (might not exist). Optional ''query'' parameter, see [[Help:Variable]].
|- <!-- intentionally nbsp instead of sp for formatting reasons -->
| <nowiki>{{urlencode:x&#160;y&#160;@}}</nowiki>
| <code>{{urlencode:x y @}}</code>
| '''[MW1.7+]''' Encodes variable values for use in external links.  [http://svn.wikimedia.org/viewvc/mediawiki?view=rev&revision=14273]
|- <!-- intentionally nbsp instead of sp for formatting reasons -->
| <nowiki>{{anchorencode:x&#160;#y&#160;@}}</nowiki>
| <code>{{anchorencode:x #y @}}</code>
| '''[MW1.8+]''' Encodes variable values for use in section anchors. [http://svn.wikimedia.org/viewvc/mediawiki?view=rev&revision=16279]
|-
|-
| <nowiki>{{fullurl:x y @}}</nowiki><br /><nowiki>{{fullurle:x y @}}</nowiki><br /><nowiki>{{fullurl:m:a|b=c}}</nowiki>
| <nowiki>{{localurl:x y @}}</nowiki><br /><nowiki>{{localurle:x y @}}</nowiki><br /><nowiki>{{localurl:a|b=c}}</nowiki><br /><nowiki>{{localurl:Venciclopedia:Category}}</nowiki>
| <small>{{fullurl:x y @}}<br />{{fullurle:x y @}}<br />{{fullurl:m:a|b=c}}</small>
| <code>{{localurl:x y @}}<br />{{localurle:x y @}}<br />{{localurl:a|b=c}}<br />{{localurl:Venciclopedia:Category}}</code>
| '''[MW1.5+]''' Returns the full URL of a given page. Optional ''query'' parameter as for <tt>localurl:</tt>.
| URL local de una pagina (que puede no existir).
|}{{-}}
|}


=== Formatting ===
== Modificadores de imagenes ==
{| {{Tabla Generica}}
=== Tamaño ===
! Código
! Ejemplo
! Explicación
|-
| <nowiki>{{#language:}}</nowiki>
| <nowiki>{{#language:da}}</nowiki> = <code>{{#language:da}}</code>
| '''[MW1.7+]''' Native name of language code.
|-
| <nowiki>{{lc:}}</nowiki>
| <nowiki>{{lc:AbC dEf}}</nowiki> = <code>{{lc:AbC dEf}}</code>
| '''[MW1.5+]''' LowerCase
|-
| <nowiki>{{lcfirst:}}</nowiki>
| <nowiki>{{lcfirst:Ab Cd}}</nowiki> = <code>{{lcfirst:Ab Cd}}</code>
| '''[MW1.5+]''' LC first char.
|-
| <nowiki>{{uc:}}</nowiki>
| <nowiki>{{uc:aBc DeF}}</nowiki> = <code>{{uc:aBc DeF}}</code>
| '''[MW1.5+]''' UpperCase
|-
| <nowiki>{{ucfirst:}}</nowiki>
| <nowiki>{{ucfirst:aB cD}}</nowiki> = <code>{{ucfirst:aB cD}}</code>
| '''[MW1.5+]''' UC first char.
|-
| <nowiki>{{formatnum:}}</nowiki>
| <nowiki>{{formatnum:-299792458.56789}}</nowiki> = <code>{{formatnum:-299792458.56789}}</code>
| '''[MW1.7+]''' Add [[w:Decimal_separator#Thousands_separator|decimal separators]] according to the wiki's default locale. Leading minus and plus are recognized.
|-
|<nowiki>{{padleft:}}</nowiki><br /><br /><br /><br /><br /><nowiki>{{padright:}}</nowiki><br />
|
<nowiki>{{padleft:7|3|0}}</nowiki> = <code>{{padleft:7|3|0}}</code><br/><br/>
<nowiki>{{padleft:0|3|0}}</nowiki> = <code>{{padleft:0|3|0}}</code> (bug)<br/><br/>
<nowiki>{{padleft:bcd|6|a}}</nowiki> = <code>{{padleft:bcd|6|a}}</code><br/>
<nowiki>{{padleft:café|8|-}}</nowiki> = <code>{{padleft:café|8|-}}</code>(<==Bug effect)<br />
<nowiki>{{padleft:cafe|8|-}}</nowiki> = <code>{{padleft:cafe|8|-}}</code><br />
 
<nowiki>{{padleft:bcd|6|{{!}}}}</nowiki> = <code>{{padleft:bcd|6|{{!}}}}</code><br/>
<br/>
<nowiki>{{padright:bcd|6|a}}</nowiki> = <code>{{padright:bcd|6|a}}</code><br />
<nowiki>{{padright:0|6|a}}</nowiki> = <code>{{padright:0|6|a}}</code> (bug)<br />
 
|valign="top"|<br />First case is, for example, applicable to years in a category... giving an ordered year to sort by pipetricks order, or any such ordering where left extended zeros allow a proper sorting.<br /><br /> '''[MW1.8+]''' Pads a string with a character to the specified width. Note that there's a little bug that interprets non-[[w:US-ASCII|US-ASCII]] characters as two, instead of one character (see the difference in''' ''café'' and ''cafe'' '''in the examples.)
 
It does not seem possible to use padleft and padright for padding with characters with a multi-character code, such as <code>&amp;nbsp;</code>, which would be useful with padleft for [[Help:Sorting|sorting tables]] with Javascript.
 
Padding "0" does not work, it returns the same. This seems to be a bug.<ref>Function pad in includes/CoreParserFunctions.php puts, oddly, the $string itself as a condition for the padding. To be reported as bug.</ref>
|}{{-}}
 
With regard to #language and {{tim|n local}}, see also:
*[[List of Wikipedias/local names]] - shows both names for all languages, without automatic comparison
*[[List of Wikipedias/local names/diff]] - values of [[Help:Magic words#Formatting|#language]] for which <nowiki>{{n local}}</nowiki> contains a different name.
*[[List of Wikipedias/local names/diff 1]] - for languages where the two names are different, shows both; due to the {{peisl}} the end of the table is messed up
 
== Template modifiers ==
{| {{Tabla Generica}}
! Uso
! Explicación
|-
| <nowiki>{{:xyz}}</nowiki>
| A bare colon is not a template modifier, it's the prefix for the main namespace. Test e.g. article {&#123;:UTC&#125;} vs. template {&#123;UTC&#125;}.<br>Using this syntax you include the text of the main namespace article xyz in another article.
|-
| <nowiki>{{int:xyz}}</nowiki>
| Same as <nowiki>{{MediaWiki:xyz}}</nowiki>, except standard message translation is applied depending on subpages and content/user/uselang language. Rendered as {{int:xyz}} if [[MediaWiki:xyz]] doesn't exist. See also [[Help:System message]].
|-
| <nowiki>{{msg:xyz}}</nowiki>
| Even if there is a magic word named "xyz", use template:xyz unless the template doesn't exist (equivalent to <nowiki>{{template:xyz}}</nowiki>). Normally, magic words have priority when there is a conflict.
|-
| <nowiki>{{msgnw:xyz}}</nowiki>
| The unevaluated wikitext is rendered. See [[Help:Template#msgnw|msgnw]].
|-
| <nowiki>{{raw:xyz}}</nowiki>
| '''[MW1.6+]''' Equivalent to <code><nowiki>{{msg:xyz}}</nowiki></code> above<ref>[http://svn.wikimedia.org/viewvc/mediawiki?view=rev&revision=12925 Wikimedia SVN revision 12925]</ref>.
|-
| <nowiki>{{subst:xyz}}</nowiki>
| In the wikitext, the tag is substituted by the ''content'' (single-level evaluation only), see [[Help:Substitution]].
|}{{-}}
 
== Image modifiers ==
:''For details see [[w:en:Wikipedia:Extended image syntax]].''
These are [[Help:Image page|image]] modifiers used in <code><nowiki>[[Image:title.ext|modifier|...|modifier]]</nowiki></code> links. Some are mutually exclusive, and then the last specified wins.
 
=== Size ===
The last unrecognized modifier is used as '''caption''' for ''framed'' images or together with ''thumbnail''s. It's also used as description <tt>alt=</tt>''text''.
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
Línea 347: Línea 197:
| framed<br/>frame<br/>enframed
| framed<br/>frame<br/>enframed
| <nowiki>[[Image:Mediawiki.jpg|framed]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|framed]]</nowiki>
| Places an image in a ''frame'' with a description. Uses original size and stubbornly ignores width parameter if given.<br>In general, far better to use thumb, as is only suitable for small images.
| Pone la imagen en un ''marco'' con una descripción. Usa el tamaño original e ignora el parámetro de tamaño. Mejor usar "thumb".
|-
|-
| border
| border
| <nowiki>[[Image:Mediawiki.jpg|border]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|border]]</nowiki>
| Shows a 1px border around the image.
| Muestra un borde de 1px alrededor de una imagen.
|-
|-
| thumbnail<br/>thumb
| thumbnail<br/>thumb
| <nowiki>[[Image:Mediawiki.jpg|thumbnail]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|thumbnail]]</nowiki>
| Modifies image size, sets it dependent on user's favorite thumbnail size in one's preferences, or on the given width parameter (see below).
| Modifica el tamaño de la imagen dependiendo de las preferencias del usuario, o un parámetro especifico.
|-
|-
| thumb=''xyz''
| thumb=''xyz''
| <nowiki>[[Image:Mediawiki.jpg|thumb=Wiki.jpg]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|thumb=Wiki.jpg]]</nowiki>
| Manualthumb: instead of displaying an automatically-sized thumbnail for <var>Mediawiki.jpg</var>, display the image <var>Wiki.jpg</var>.
| Manualthumb: en vez de mostrar una imagen pequeña automáticamente cambiada de tamaño para <var>Mediawiki.jpg</var>, muestra la imagen <var>Wiki.jpg</var>.
|-valign="top"
|-valign="top"
| ''width'' px<br>100x200px
| ''width'' px<br>100x200px
| <nowiki>[[Image:Mediawiki.jpg|40px]]</nowiki><br><nowiki>[[Image:Mediawiki.jpg|100x200px]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|40px]]</nowiki><br><nowiki>[[Image:Mediawiki.jpg|100x200px]]</nowiki>
| Scales image to given ''width''&#160; in pixels<br>Scales image to no more than 100 pixels wide and no more than 200 high, but image scaled to retain its true aspect ratio within the boundary specified.
| Redimensiona imagen a una "anchura" especificada en pixels<br>Redimensiona imagen a no mas de 100 pixels de ancho y no mas de 200 de alto, pero la misma mantiene sus aspecto original.
|}{{-}}
|}


=== Position ===
=== Posición ===
:''For details see [[Help:Images and other uploaded files]]''
The positions are mutually exclusive; the last specified wins. [[:Template:-]] can stop floating. For inline images only modifier ''px'' (see above) is supported.
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
Línea 376: Línea 224:
| right
| right
| <nowiki>[[Image:Mediawiki.jpg|right]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|right]]</nowiki>
| Modifies position, floats the image to the right.
| Modifica posición, la imagen flota a la derecha.
|-
|-
| <nowiki>left</nowiki>
| <nowiki>left</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|left]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|left]]</nowiki>
| Modifies position, floats the image to the left.
| Modifica posición, la imagen flota a la izquierda.
|-
|-
| <nowiki>none</nowiki>
| <nowiki>none</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|none]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|none]]</nowiki>
| Explicitly states that the image should not float.
| Ordena específicamente que la imagen no flote.
|-
|-
| center<br />centre
| center<br />centre
| <nowiki>[[Image:Mediawiki.jpg|center]]</nowiki>
| <nowiki>[[Image:Mediawiki.jpg|center]]</nowiki>
| Modifies position, like ''none'' but centered.  
| Modifica posición, como "nada" pero centrado.  
|}{{-}}
|}


== Miscellany ==
== Misceláneo ==
{| {{Tabla Generica}}
{| {{Tabla Generica}}
! Código  
! Código  
! Ejemplo
! Ejemplo
! Explicación
! Explicación
|-
| <nowiki>{{DISPLAYTITLE:</nowiki>''xyz''<nowiki>}}</nowiki>
|
| '''[MW 1.7+]''' Set the page's title [http://svn.wikimedia.org/viewvc/mediawiki?view=rev&revision=13572], enabled in Wikimedia projects since June 2007 ([http://svn.wikimedia.org/viewvc/mediawiki?view=rev&revision=23393]). Also see {{h:mwg|AllowDisplayTitle}}.
|-
| <nowiki>{{DIRMARK}}</nowiki><br /><nowiki>{{DIRECTIONMARK}}</nowiki>
| <code>{{DIRMARK}}</code><br /><code>{{DIRECTIONMARK}}</code>
| '''[MW1.7+]''' u+200E left to right or u+200D right to left mark
|-
| <nowiki>{{CONTENTLANGUAGE}}</nowiki>
| <code>{{CONTENTLANGUAGE}}</code>
| '''[MW1.7+]''' code of the site's default interface language ({{h:mwg|LanguageCode}})
|-
| <nowiki>{{DEFAULTSORT:xyz}}</nowiki>
| <nowiki>{{DEFAULTSORT:xyz}}</nowiki>
| '''[MW1.10+]''' Sets a default [[Help:Categories#Sort_key|category sort key]] for the whole current page (also applying for category tags before this tag)<ref>"[[w:Wikipedia:Wikipedia Signpost/2007-01-02/Technology report|Technology report]]", en-Wikipedia Signpost, January 2007</ref>.
|-
|-
| <nowiki>#REDIRECT</nowiki>  
| <nowiki>#REDIRECT</nowiki>  
| <code>#REDIRECT&#160;[&#91;target&#93;]</code><br />at top of source page
| <code>#REDIRECT&#160;[&#91;target&#93;]</code>
| Creates a [[Help:Redirect|redirect]] to another page.
| Crea una redirección a otra pagina page.
|}{{-}}
|}
 
===Language-dependent word conversions===
{| {{Tabla Generica}}
! Código
! Ejemplo
! Explicación
|-
| {&#123;<small> CURRENTMONTHNAMEGEN </small>&#125;}
| <code>{{CURRENTMONTHNAMEGEN}}</code>
| [[w:genitive case|Genitive form]] of month name used for Czech, Polish, Ukrainian[http://svn.wikimedia.org/svnroot/mediawiki/trunk/phase3/languages/]
|-
| {&#123;grammar:''case &#124; word'' &#125;}
| <nowiki>{{grammar:7sg|Wikipedie}}</nowiki><br />on [[:cs:]] is <code>Wikipedií</code>.
| Derived word forms in inflected languages like [[:cs:|Czech]] [http://svn.wikimedia.org/svnroot/mediawiki/trunk/phase3/languages/classes/LanguageCs.php]
|-
| {&#123;plural:''count &#124;form1 &#124;form2'' &#125;}<br />{&#123;plural:''count&#160;&#124;1st&#160;&#124;&#160;2nd&#160;&#124;&#160;3rd&#160;''&#125;}
| <nowiki>{{plural: 2 | is | are }}</nowiki><br />outputs <code>{{plural: 2 | is |are }}</code><br /><nowiki>{{plural: 0 | this | these }}</nowiki><br />outputs <code>{{plural: 0 |this | these }}</code>
| ''count'' '''1''' yields ''form1'' (singular), [[w:Plural|plural]] transformations are used for languages like [[:ru:|Russian]] [http://svn.wikimedia.org/svnroot/mediawiki/trunk/phase3/languages/classes/LanguageRu.php] based on "count mod 10".
|}{{-}}
 
"Grammar" and "Plural" are language-dependent functions, defined in [http://svn.wikimedia.org/svnroot/mediawiki/trunk/phase3/languages/classes/LanguageCs.php], [http://svn.wikimedia.org/svnroot/mediawiki/trunk/phase3/languages/classes/LanguageRu.php], etc. (note that in PHP, the modulo operator is the percent sign).
 
"Grammar" can either be applied to predefined words only, or to arbitrary words, depending on whether the definition is just a 2D array, or involves string manipulations. See also [[:cs:Šablona:Wikivar/GRAMMAR]].
 
"Plural" is a site-language-dependent switch function, controlled by function convertPlural in Language.php (which distinguishes between 1 and "not 1"), for some languages overridden in Languagexx.php, e.g. for French (which distinguishes between <=1 and >1) and Russian (oddly, first option is 1, 21, 31,.., 91, 101, 121, .., second is 2, 3, 4, 22, 23, 24, 31, 32, 33, 41,.., 94, 102, 103, 104,.., 122, 123,.., and else the third).
 
As opposed to [[ParserFunctions]], "plural" accepts points and commas in numbers and interprets them in a site-language-specific way (depending on $separatorTransformTable in Messagesxx.php); on this site:
*<nowiki>{{plural:1.000|a|b|c}}</nowiki> gives {{plural:1.000|a|b|c}}
*<nowiki>{{plural:1,000|a|b|c}}</nowiki> gives {{plural:1,000|a|b|c}}
 
(on e.g. the German and the Dutch sites reversed w.r.t. the result on English sites).
 
"Plural" is used in various system messages, e.g. {{msg|nmembers}}, where it uses interface language instead of site language.


[[Categoría:Venciclopedia:Ayuda]]
[[Categoría:Venciclopedia:Ayuda]]

Revisión del 09:40 21 sep 2007

Esta es una lista de los códigos de edición o palabras mágicas que se pueden utilizar para modificar tus páginas. Usar con juicio.

Una "palabra mágica" es un símbolo que es reconocido por el sistema y lo obliga a mostrar algo diferente del símbolo en si. Una palabra mágica puede ser:

  • una palabra en mayúsculas precedida y seguida de dos subrayados. Ejemplo: __NOTOC__;
  • un objeto XML, código similar al HTML, precedido por "<" (usando "/" para cerrar el efecto del código) y seguido por ">", como en '''...'''
  • una función parser: similar a una plantilla, es una palabra precedida por los símbolos "{{" y seguida por "}}", y opcionalmente parámetros entre barras verticales (|), excepto que la parte antes de la barra (o sin la barra, el texto dentro de las llaves) contiene dos puntos (":"). Ejemplo: {{ns:3}} y {{#ifexpr:{{{1}}}>3|large|small}}
  • una variable: similar a una plantilla sin parametros, una palabra precedida por los símbolos "{{" y seguida de "}}", excepto que la palabra usada está toda en mayúsculas. Ejemplo: {{CURRENTDAY}}
  • un modificador de plantillas.
  • un modificador de imágenes.

Los símbolos usados en esta página como "[MW1.5+]" indican la primera versión en que la función se hizo disponible. "XYZ" indica el texto que añadirian los usuarios al personalizar las "palabras mágicas".

Palabras mágicas entre subrayados dobles

Código Explicación
__NOEDITSECTION__ Oculta los enlaces a editar en los encabezados.
__NEWSECTIONLINK__ [MW1.7+] Añade un enlace "+" a lado de la pestaña de editar para crear una nueva sección en una página que no sea de discusión.
__NOCONTENTCONVERT__
__NOCC__
Hace que no se conviertan el idioma del contenido (caracteres y fase) en los artículos; por ejemplo, Chino zh with zh_cn, zh_tw, zh_sg, zh_hk.
__NOGALLERY__ [MW1.7+] Permite que las imagenes en una categoria se muestren en enlaces en vez de como en galería.
__NOTITLECONVERT__
__NOTC__
Como __NOCC__ pero solo afecta los títulos de los artículos.


Códigos estilo XML

nowiki: <nowiki>'''...'''</nowiki>, deshabilita el efecto de plantillas, enlaces, formatos, etc. <nowiki>'''[[{{XYZ}}]]'''</nowiki> da [[{{XYZ}}]]

noinclude: <noinclude>'''...'''</noinclude>, hace que un texto aparezca en la página original pero no en la página que se use como en las plantillas. Así se pueden categorizar plantillas sin que también se categoricen las paginas en las que se incluyen.

includeonly: <includeonly>'''...'''</includeonly>, lo contrario del anterior. Hace que un texto en una plantilla solo aparezca en el artículo donde se usa. Por ejemplo: categorías.

onlyinclude: <onlyinclude>'''...'''</onlyinclude>, igual que