Diferencia entre revisiones de «Ayuda:Enlace externo»
Sin resumen de edición |
Sin resumen de edición |
||
Línea 1: | Línea 1: | ||
{{Por traducir}} |
|||
⚫ | |||
''[[:en:Help:URL|Texto original en inglés]]'' |
|||
---- |
|||
⚫ | |||
La forma de incluirlos es: <code><nowiki>[http://www.example.org nombre para mostrar]</nowiki></code>, que se mostrará [http://www.example.org nombre para mostrar], con el texto que queremos mostrar separado de la URL por un espacio en blanco. Los enlaces para los que no se especifique texto se numerarán: <code><nowiki>[http://www.example.org]</nowiki></code> se muestra [http://www.example.org]. Si el enlace se escribe sin corchetes se mostrará íntegramente, como http://www.example.org . |
La forma de incluirlos es: <code><nowiki>[http://www.example.org nombre para mostrar]</nowiki></code>, que se mostrará [http://www.example.org nombre para mostrar], con el texto que queremos mostrar separado de la URL por un espacio en blanco. Los enlaces para los que no se especifique texto se numerarán: <code><nowiki>[http://www.example.org]</nowiki></code> se muestra [http://www.example.org]. Si el enlace se escribe sin corchetes se mostrará íntegramente, como http://www.example.org . |
||
Línea 65: | Línea 70: | ||
#: '''1111''' 0000 '''10''' 010000 '''10''' 000000 '''10''' 000000 would be %F0%90%80%80. |
#: '''1111''' 0000 '''10''' 010000 '''10''' 000000 '''10''' 000000 would be %F0%90%80%80. |
||
==Enlaces externos a un proyecto== |
|||
==URLs of pages within the projects== |
|||
Las páginas de proyectos de WikiMedia pueden enlazarse por medio de [[Ayuda:Interwiki|interwikis]]. Sin embargo, en ocasiones puede ser útil enlazarlas por medio de enlaces externos, ya que estos enlaces permiten pasar parámetros por medio de la dirección URL. |
|||
⚫ | |||
===Nombres de dominio de WikiMedia=== |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
*xx.wiktionary.org |
*xx.wiktionary.org |
||
*xx.wikiquote.org |
*xx.wikiquote.org |
||
Línea 77: | Línea 86: | ||
*sep11.wikipedia.org |
*sep11.wikipedia.org |
||
Una URL que empiece por ''www.wikipedia.org'' redirige a la wikipedia en inglés. Sólo la propia dirección http://www.wikipedia.org a secas conduce a un portal multilingüe. |
|||
En proyectos que no son de WikiMedia la "w/" en URLs tales como: |
|||
http://www.wikipedia.org/w/wiki.phtml?title=Main_Page&action=history |
http://www.wikipedia.org/w/wiki.phtml?title=Main_Page&action=history puede variar, como: |
||
*http://www.disinfopedia.org/wiki.phtml?title=Disinfopedia_Main_Page&action=history |
*http://www.disinfopedia.org/wiki.phtml?title=Disinfopedia_Main_Page&action=history |
||
*http://wikitravel.org/en/index.php?title=Main_Page&action=history |
*http://wikitravel.org/en/index.php?title=Main_Page&action=history |
||
Línea 106: | Línea 115: | ||
This works for a link in external link style to a page in the same project. We can use localurl for a link to a project which uses the same string in the URL between the server name and the question mark ([http://www.mediawiki.org/wiki/Help:$wgScript $wgScript], on Wikimedia "/w/index.php"), but not for links to other projects. |
This works for a link in external link style to a page in the same project. We can use localurl for a link to a project which uses the same string in the URL between the server name and the question mark ([http://www.mediawiki.org/wiki/Help:$wgScript $wgScript], on Wikimedia "/w/index.php"), but not for links to other projects. |
||
===Versiones antiguas de páginas=== |
|||
==Old versions of pages== |
|||
All old versions of all pages are numbered (with [[m:oldid|oldid]]) approximately in the order of becoming an old version, i.e. in chronological order of the next edit of the same page. |
|||
Todas las versiones antiguas de las páginas están numeradas en orden cronológico con un identificador llamado [[m:oldid|oldid]]. Esto permite crear enlaces directos a páginas antiguas, como se ve en estos ejemplos: |
|||
*http://meta.wikimedia.org/w/wiki.phtml?title=Help:Link&oldid=53587 - normal link to old page |
*http://meta.wikimedia.org/w/wiki.phtml?title=Help:Link&oldid=53587 - normal link to old page |
||
*http://meta.wikimedia.org/w/wiki.phtml?oldid=53587 - no page name in the URL, goes to the correct page |
*http://meta.wikimedia.org/w/wiki.phtml?oldid=53587 - no page name in the URL, goes to the correct page |
||
Línea 117: | Línea 125: | ||
See also [[Help:Page history#Linking_to_a_specific_version_of_a_page|Linking to specific versions of a page]]. |
See also [[Help:Page history#Linking_to_a_specific_version_of_a_page|Linking to specific versions of a page]]. |
||
== |
===Páginas nuevas=== |
||
Cada página está numerada según su orden de creación, por medio del índice ''page_id'' de la [[m:page table|tabla de páginas]]. |
|||
*http://meta.wikimedia.org/w/wiki.phtml?title=x&curid=9906 - gives the page with correct full name |
*http://meta.wikimedia.org/w/wiki.phtml?title=x&curid=9906 - gives the page with correct full name |
||
Línea 129: | Línea 137: | ||
From [[m:MediaWiki 1.5|MediaWiki 1.5]] page versions get a number "oldid" as soon as they are created; they are produced by variable <nowiki>{{REVISIONID}}</nowiki>. The URL is like in the previous section. |
From [[m:MediaWiki 1.5|MediaWiki 1.5]] page versions get a number "oldid" as soon as they are created; they are produced by variable <nowiki>{{REVISIONID}}</nowiki>. The URL is like in the previous section. |
||
== |
===Edición=== |
||
Puede invocarse directamente una página en modo de edición de este modo: |
|||
Examples: |
|||
⚫ | |||
* |
*Para editar una sección: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=5 |
||
* |
*Para añadir al final del artículo: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=1000 (usando un número de sección muy alto) |
||
⚫ | |||
*Ditto with [[Help:Edit summary#.22Post_a_comment.22_feature|"Post a comment" feature]]: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=new |
*Ditto with [[Help:Edit summary#.22Post_a_comment.22_feature|"Post a comment" feature]]: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=new |
||
== |
===Miscelánea=== |
||
In some cases of caching problems, to update a page it can help to use "action=purge", in a URL like {{SERVER}}{{localurl:{{NAMESPACE}}:{{PAGENAMEE}}|action=purge}} |
|||
Se puede obtener el [[w:wikitexto|wikitexto]] plano de una página directamente de una URL del tipo: |
|||
==Miscellaneous== |
|||
⚫ | |||
Otras acciones que se pueden especificar son: |
|||
⚫ | |||
* action=view |
|||
* action=watch |
|||
Other actions are view, watch, unwatch, delete, revert, rollback, unprotect, info, markpatrolled, validate, render, deletetrackback, and history. (These rarely need to be entered explicitly, as the useful ones are prelinked at various tabs and buttons. Several of these actions require administrator privileges. Other users do not have the link; if they try the URL they get the message in [[MediaWiki:Badaccesstext]].) |
|||
* action=unwatch |
|||
* action=delete |
|||
* action=revert |
|||
* action=purge |
|||
* action=rollback |
|||
* action=unprotect |
|||
* action=info |
|||
* action=markpatrolled |
|||
* action=validate |
|||
* action=render |
|||
* action=deletetrackback |
|||
* action=history. |
|||
Las más usuales de entre estas, pueden invocarse más fácilmente mediante los enlaces o pestañas de las páginas. Para algunas es necesarios disponer de privilegios de administrador, los usuarios comunes obtendrían el mensaje de error especificado en [[MediaWiki:Badaccesstext]]. |
|||
==Kinds of dead links== |
==Kinds of dead links== |
||
Línea 160: | Línea 179: | ||
*http://meta.wikimedia.org/w/index.php?title=Help:URL#abc |
*http://meta.wikimedia.org/w/index.php?title=Help:URL#abc |
||
== |
==Véase también== |
||
*[[ |
*[[Ayuda:Espacio de nombres]] |
||
*[[m:Eliminating index.php from the url]] |
*[[m:Eliminating index.php from the url]] |
||
*{{h:mwg|UrlProtocols}} |
*{{h:mwg|UrlProtocols}} |
||
*[[m:URI schemes]] - how to request <tt>worldwind:</tt> and other scheme cruft. |
*[[m:URI schemes]] - how to request <tt>worldwind:</tt> and other scheme cruft. |
||
[[ |
[[Categoría:Ayuda]] |
||
[[en:Help:URL]] |
Revisión del 11:32 1 nov 2006
Los enlaces externos especifican directamente una dirección URL para enlazar a una página cualquiera de internet.
La forma de incluirlos es: [http://www.example.org nombre para mostrar]
, que se mostrará nombre para mostrar, con el texto que queremos mostrar separado de la URL por un espacio en blanco. Los enlaces para los que no se especifique texto se numerarán: [http://www.example.org]
se muestra [1]. Si el enlace se escribe sin corchetes se mostrará íntegramente, como http://www.example.org .
A diferencia de los enlaces internos, [http://www.example.org a]s aparece como as.
Estos enlaces llevan asociada la etiqueta de clase "external".
- Consulte información más detallada sobre URLs en los enlaces externos
- Special:Linksearch encuentra todas las páginas que enlazan con un sitio web determinado.
URLs in external links
A link in external link style can be of the forms:
- target: http://meta.wikimedia.org/ is rendered as http://meta.wikimedia.org/
- [ target label ], with a blank space in between: [http://meta.wikimedia.org/ wikimedia] gives wikimedia (see also Help:Piped link)
- [ target ] - these are automatically labelled with serial numbers 1, 2, 3, ...: [http://meta.wikimedia.org/] gives [2]
The target is a URL which can start with "http://" or "ftp://";
"file://" does not work by default. If enabled it only works in MSIE. To enable it, add a $wgUrlProtocols entry to LocalSettings.php; see the $wgUrlProtocols in DefaultSettings.php for example.
All characters of the URL must be among:
A-Z a-z 0-9 ._\/~%-+&#?!=()@
If a URL contains a different character it should be converted; for example, ^ has to be written %5e, the hexadecimal ASCII value with a percent sign in front. A blank space can also be converted into an underscore.
Conversion:
" # $ % & ' * , : ; %20 %22 %23 %24 %25 %26 %27 %2a %2c %3a %3b
< > ? [ ] ^ ` { | } %3c %3e %3f %5b %5d %5e %60 %7b %7c %7d
For the other characters either the code or the character can be used in internal and external links, they are equivalent. The system does a conversion when needed. E.g.
[[%C3%80_propos_de_M%C3%A9ta]]
is rendered as À_propos_de_Méta, almost like À propos de Méta, which leads to this page on Meta with in the address bar the URL
http://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta
while http://meta.wikipedia.org/wiki/À_propos_de_Méta leads to the same.
See also (in Wikipedia): Internationalized domain names and .
Percent-encoding
For ASCII characters (up to decimal 127, hex. 7F) percent-encoding simply means adding % to the hex. value, e.g. for a tilde ~ (decimal 126, hex. 7E) it's %7E. Otherwise (non-ASCII) convert it first to UTF-8 and then percent-encode it. Example:
- Convert the character to Unicode, e.g. Latin-1 192 (hex. C0) to À (u+00C0), or windows-1252 131 (hex. 8B) to Š (u+0160).
- Convert Unicode to bits, 00000000 11000000 (u+00C0), or 00000001 01100000 (u+0160).
- Build groups of six bits from the right adding leading zeros if necessary until the rest are zeros: 000011 000000 (u+00C0), or 000101 100000 (u+0160).
- Add 10 in front of all but the leftmost group. 2 bits + 6 bits = 8bits, also known as octet.
- If there are only two groups, and the first (left) starts with 0:
- Add 11 to the left: 11 000011 10 0000000 (u+00C0), or 11 000101 10 100000 (u+0160).
- Convert the octets to hex., add percent in front, ready: %C3%80 (u+00C0), or %C5%A0 (u+0160).
- If the first (left) of two groups starts with 1:
- Add 111 00000 10 to the left, then percent-encode three octects, %E0%??%??
- If there are three groups, the first (left) starting with 00 (000001 up to 001111):
- Replace 00 by 111 0, percent-encode three octects, ready, result %E?%??%??.
- Otherwise it's at least 010000 000000 000000 (u+10000) needing four UTF-8 octets:
- 1111 0000 10 010000 10 000000 10 000000 would be %F0%90%80%80.
Enlaces externos a un proyecto
Las páginas de proyectos de WikiMedia pueden enlazarse por medio de interwikis. Sin embargo, en ocasiones puede ser útil enlazarlas por medio de enlaces externos, ya que estos enlaces permiten pasar parámetros por medio de la dirección URL.
Nombres de dominio de WikiMedia
Véase w:Wikipedia:URLs. On other projects everything works the same, except that the domain names vary:
- xx.wikipedia.org siendo xx el sódigo de idioma (véase Lista de wikipedias)
- meta.wikimedia.org (meta.wikipedia.org redirige allí)
- xx.wiktionary.org
- xx.wikiquote.org
- xx.wikibooks.org
- xx.wikisource.org
- sep11.wikipedia.org
Una URL que empiece por www.wikipedia.org redirige a la wikipedia en inglés. Sólo la propia dirección http://www.wikipedia.org a secas conduce a un portal multilingüe.
En proyectos que no son de WikiMedia la "w/" en URLs tales como: http://www.wikipedia.org/w/wiki.phtml?title=Main_Page&action=history puede variar, como:
- http://www.disinfopedia.org/wiki.phtml?title=Disinfopedia_Main_Page&action=history
- http://wikitravel.org/en/index.php?title=Main_Page&action=history
The default is /wiki/wiki.phtml, with in DefaultSetting.php [3]:
$wgScriptPath = "/wiki"; $wgScript = "{$wgScriptPath}/wiki.phtml";
There may be other variations, compare:
Use in templates
For use in templates, note that all URLs on e.g. the English Wikipedia can be written in the form
http://en.wikipedia.org/w/index.php?title={{{1}}}
This requires {{{1}}} to be written with underscores and escape codes (if applicable). To benefit from the conversion carried out by fullurl, two parameters are needed:
{{fullurl:{{{1}}}|{{{2}}}}}
(see Template talk:Url 2p). An example with the second parameter in fullurl fixed is Plantilla:Tiw containing the link [{{fullurl:Template:{{{1}}}|action=edit}} {{MediaWiki:Edit}} {{{2|{{{1}}}}}}].
This works for a link in external link style to a page in the same project. We can use localurl for a link to a project which uses the same string in the URL between the server name and the question mark ($wgScript, on Wikimedia "/w/index.php"), but not for links to other projects.
Versiones antiguas de páginas
Todas las versiones antiguas de las páginas están numeradas en orden cronológico con un identificador llamado oldid. Esto permite crear enlaces directos a páginas antiguas, como se ve en estos ejemplos:
- http://meta.wikimedia.org/w/wiki.phtml?title=Help:Link&oldid=53587 - normal link to old page
- http://meta.wikimedia.org/w/wiki.phtml?oldid=53587 - no page name in the URL, goes to the correct page
- http://meta.wikimedia.org/w/wiki.phtml?title=Help:Link&oldid=53588 - number and name do not correspond; the name is ignored
- http://meta.wikimedia.org/w/wiki.phtml?title=abc&oldid=53587 - non-existing page name; oldid is ignored, works like going to a non-existing page, except for the links to assumed previous and next versions, and on editing, for the warning of editing an old version of a page.
See also Linking to specific versions of a page.
Páginas nuevas
Cada página está numerada según su orden de creación, por medio del índice page_id de la tabla de páginas.
- http://meta.wikimedia.org/w/wiki.phtml?title=x&curid=9906 - gives the page with correct full name
Conversely, most query output provides page names as well as page id's, e.g. http://meta.wikimedia.org/w/query.php?titles=Hilfe:Zeitleiste
See also m:Multiple titles.
From MediaWiki 1.5 page versions get a number "oldid" as soon as they are created; they are produced by variable {{REVISIONID}}. The URL is like in the previous section.
Edición
Puede invocarse directamente una página en modo de edición de este modo:
- Para editar la página completa: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit
- Para editar una sección: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=5
- Para añadir al final del artículo: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=1000 (usando un número de sección muy alto)
- Ditto with "Post a comment" feature: http://meta.wikimedia.org/w/wiki.phtml?title=Help:URL&action=edit§ion=new
Miscelánea
Se puede obtener el wikitexto plano de una página directamente de una URL del tipo:
//es.wikiversity.org/w/index.php?title=Ayuda:Enlace_externo&action=raw
Otras acciones que se pueden especificar son:
- action=view
- action=watch
- action=unwatch
- action=delete
- action=revert
- action=purge
- action=rollback
- action=unprotect
- action=info
- action=markpatrolled
- action=validate
- action=render
- action=deletetrackback
- action=history.
Las más usuales de entre estas, pueden invocarse más fácilmente mediante los enlaces o pestañas de las páginas. Para algunas es necesarios disponer de privilegios de administrador, los usuarios comunes obtendrían el mensaje de error especificado en MediaWiki:Badaccesstext.
Kinds of dead links
There can be various kinds of errors in the URL. With some the server is not even reached, with others the server takes some action. The server may also go to the correct page and just ignore a wrong parameter or anchor.
- //es.wikiversity.org{{localurl:%abc}}
- http://meta.wikimedia.or/
- //es.wikiversity.orgabc
- http://met.mediawiki.org
- //es.wikiversity.org/abc
- http://meta.wikimedia.org/w/index.php?title=Help:URL&action=abc
- http://meta.wikimedia.org/w/index.php?title=Help:URL&act=abc
- http://meta.wikimedia.org/w/index.php?title=Help:URL#abc
Véase también
- Ayuda:Espacio de nombres
- m:Eliminating index.php from the url
- Plantilla:H:mwg
- m:URI schemes - how to request worldwind: and other scheme cruft.