Content deleted Content added
m →Permitted HTML: Cleanup; Update |
|||
Line 3:
The following [[HTML element]]s are currently permitted:
{{Colbegin|3}}
* [[HTML element#General|<abbr>]]
* [[HTML element#Presentation|<b>]]
* [[HTML element#Presentation|<big>]]
Line 21:
* [[HTML element#Presentation|<font>]]
* [[HTML element#Basic Text|<h1>]]
* [[HTML element#Basic Text|<h2>]]
* [[HTML element#Basic Text|<h3>]]
Line 34 ⟶ 33:
* [[HTML element#Basic Text|<p>]]
* [[HTML element#Other Block Elements|<pre>]]
* [[Ruby character#Ruby markup|<rb>]]
* [[Ruby character#Ruby markup|<rp>]]
* [[Ruby character#Ruby markup|<rt>]]
* [
* [[HTML element#Presentation|<s>]]
* [[HTML element#Presentation|<small>]]
Line 55 ⟶ 53:
* [[HTML element#Computer Phrase Elements|<var>]]
* [[HTML element#HTML Comment|<!-- ... -->]]
{{Colend}}
For many HTML elements, more convenient wikitext code is available, see [[Help:Editing]]. On the other hand, HTML tags allow an <
▲For many HTML elements, more convenient wikitext code is available, see [[Help:Editing]]. On the other hand, HTML tags allow an <tt>id</tt> that can be referenced in one's [[Help:User style|user style]] CSS, and allows the tag to be used as link target.
▲For example, the anchor element <tt><a></tt> is not allowed, so the wikitext
▲: <code><nowiki><a href="http://meta.wikimedia.org/">Main Page</a></nowiki></code>
is treated like the wikitext
▲: <code><nowiki>&lt;a href="http://meta.wikimedia.org/"&gt;Main Page&lt;/a&gt;</nowiki></code>
and is therefore displayed as
which is unlikely to be what the editor intended. Instead of using the anchor element (<a>) the wiki markup for external reference is
▲: <a href="http://meta.wikimedia.org/">Main Page</a>
▲which is unlikely to be what the editor intended. Instead of using the anchor element (<a>) the wiki markup for external reference is recommended (enclosed in square brackets with the URL separated from the contents by a single space):
▲: <code><nowiki>[http://meta.wikimedia.org/ Main Page]</nowiki></code>
displays as:
The following excerpt from [http://svn.wikimedia.org/viewvc/mediawiki/
▲: [http://meta.wikimedia.org/ Main Page]
▲The following excerpt from [http://svn.wikimedia.org/viewvc/mediawiki/tags/REL1_6_6/phase3/includes/Sanitizer.php?view=markup Sanitizer.php] additionally shows which attributes are allowed.
<source lang="php">
$
);
$htmlsingle = array(
); $htmlsingleonly = array( # Elements that cannot have close tags
); $htmlnest = array( # Tags that can be nested--??
); $tabletags = array( # Can only appear inside table, we will close them
); $htmllist = array( # Tags used by list
'ul','ol',
);
$listtags = array( # Tags that can appear in a list
'li',
);
</source>
|