Fandom Developers Wiki
(I know this is like super confusing but I dunno if anybody would actually use this anyways)
 
(+ </includeonly>)
(One intermediate revision by one other user not shown)
Line 1: Line 1:
<noinclude>{{LangSelect}}</noinclude><includeonly>{{Infobox JavaScript
+
<noinclude>{{LangSelect}}</noinclude><includeonly>
  +
{{Languages}}
  +
{{Infobox JavaScript
 
| Status = stable
 
| Status = stable
 
| Description = {{{description|Makes linking directly to table rows more noticeable.}}}
 
| Description = {{{description|Makes linking directly to table rows more noticeable.}}}
Line 14: Line 16:
 
{{{example-text-1|In case you have a table like this:}}}
 
{{{example-text-1|In case you have a table like this:}}}
 
<pre>
 
<pre>
{| class="article-table"
+
{| class="article-table" style="width: 100%;"
 
| id="a" | A
 
| id="a" | A
 
|-
 
|-
Line 41: Line 43:
 
</pre>
 
</pre>
 
{{{example-text-2|And use [[#g]] to link to a specific row in the table, that specific row will be highlighted. You can try it on the table below.}}}
 
{{{example-text-2|And use [[#g]] to link to a specific row in the table, that specific row will be highlighted. You can try it on the table below.}}}
{| class="article-table"
+
{| class="article-table" style="width: 100%;"
 
| id="a" | A
 
| id="a" | A
 
|-
 
|-
Line 66: Line 68:
 
| id="l" | L
 
| id="l" | L
 
|}
 
|}
  +
</includeonly>

Revision as of 20:29, 29 October 2020

TableHash assigns a class to a table row that has been linked to using the ID of that row. This is useful when trying to link to information in a big table that does not warrant its own page.

Example

In case you have a table like this:

{| class="article-table" style="width: 100%;"
| id="a" | A
|-
| id="b" | B
|-
| id="c" | C
|-
| id="d" | D
|-
| id="e" | E
|-
| id="f" | F
|-
| id="g" | G
|-
| id="h" | H
|-
| id="i" | I
|-
| id="j" | J
|-
| id="k" | K
|-
| id="l" | L
|}

And use #g to link to a specific row in the table, that specific row will be highlighted. You can try it on the table below.

A
B
C
D
E
F
G
H
I
J
K
L
Text above can be found here (edit)