Template:AutoLink
More actions
AutoLink Template
This is a unified auto-linking template that can create links to different types of entities (players, characters, places, groups, businesses, etc.).
Usage
{{AutoLink|type=TYPE|target=TARGET_NAME|text=DISPLAY_TEXT}}
Parameters
- type - The type of entity to link to (players, characters, places, groups, businesses)
- target - The exact name/identifier of the entity to link to
- text - Optional display text (defaults to target name if not provided)
Supported Types
Players (type=players)
Links to player pages in the Players/ directory:
- Checks if Players/{target} exists
- If it exists, creates a link; otherwise displays as plain text
Characters (type=characters)
Links to character pages in the Characters/ directory:
- Checks if Characters/{target} exists
- If it exists, creates a link; otherwise displays as plain text
Places (type=places)
Links to Places/{target}
Groups (type=groups)
Links to Groups/{target}
Businesses (type=businesses)
Links to Businesses/{target}
Examples
{{AutoLink|type=players|target=Falcon40k}}
→ Falcon40k
{{AutoLink|type=players|target=Falcon40k|text=my friend}}
→ my friend
{{AutoLink|type=characters|target=John Tanaka}}
→ John Tanaka
{{AutoLink|type=characters|target=Jane Smith|text=his sister}}
→ his sister
{{AutoLink|type=places|target=Tokyo|text=the capital}}
→ the capital
{{AutoLink|type=businesses|target=SushiCorp}}
→ SushiCorp
Advantages
- No need to follow specific text patterns
- Explicit control over what gets linked
- Flexible display text
- Works with any entity name
- Easy to extend for new types