Difference between revisions of "Hypertext Syntax"
Jump to navigation
Jump to search
(26 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
=Absolute Essential= | =Absolute Essential= | ||
The essential markdown syntax for MediaWiki are: | The essential markdown syntax for MediaWiki are: | ||
# [[Hypertext_Syntax#Hierarchical_Markdown|Hierarchical Markdown]]: use '''<nowiki>=</nowiki>''' | |||
# [[Hypertext_Syntax#Hyperlink to other pages|Hyperlink]]: use '''<nowiki>[</nowiki>''' and '''<nowiki>]</nowiki>''' | |||
# [[Hypertext_Syntax#Transclusion from other pages|Transclusion]]: use '''<nowiki>{</nowiki>''' and '''<nowiki>}</nowiki>''' | |||
They are essential because they formally define the structure of a hyperlinked document space. | |||
==Hierarchical Markdown== | ==Hierarchical Markdown== | ||
Use a number of balanced equal signs ('''<nowiki>=</nowiki>''') to format the level of section titles. Larger number of equal signs indicates lower level. | Use a number of balanced equal signs ('''<nowiki>=</nowiki>''') to format the level of section titles. Larger number of equal signs indicates lower level. | ||
Line 6: | Line 10: | ||
|+ examples and rendered results | |+ examples and rendered results | ||
|- | |- | ||
! Input | ! Text Input !! Rendered Result | ||
|- | |- | ||
| | | | ||
Line 36: | Line 40: | ||
|| | || | ||
====Level4==== | ====Level4==== | ||
|} | |||
==Hyperlink to other pages== | |||
{| class="wikitable" | |||
|+ Linking to other pages [[mw:Help:Link|Help:Link on MediaWiki]] | |||
|- | |- | ||
| | ! Terminology !! Text Input !! Rendered Result | ||
<nowiki> | |- | ||
| '''Local Hyperlink''' || <nowiki>[[Main Page]]</nowiki> || [[Main Page]] | |||
</nowiki> | |- | ||
|| | | '''External Hyperlink''' || <nowiki>[http://wikimedia.org wikimedia website]</nowiki> || [http://wikimedia.org wikimedia website] | ||
|- | |||
| '''Piped Link''' || <nowiki>[[Main Page|This is called the Piped Link]]</nowiki> || [[Main Page|This is called the Piped Link]] | |||
|} | |} | ||
==Transclusion from other pages== | |||
{| class="wikitable" | {| class="wikitable" | ||
|+ | |+ Transcluding content from other pages or functions | ||
|- | |- | ||
! Sample Input !! Rendered Result | ! Types of Transclusion !! Sample Text Input !! Rendered Result | ||
|- | |- | ||
| <nowiki> | | locally defined page transclusion || <nowiki>{{:Paper/Algebra of Systems}}</nowiki> || {{:Paper/Algebra of Systems}} | ||
|- | |- | ||
| <nowiki> | | transcluding template page || <nowiki>{{LogicModel}}</nowiki> || {{LogicModel}} | ||
|- | |- | ||
| <nowiki> | | function invocation || <nowiki>{{#invoke:Utility|monthNumberToFullMonthName |{{CURRENTMONTH}}}}</nowiki> || {{#invoke:Utility|monthNumberToFullMonthName|{{CURRENTMONTH}}}} | ||
|} | |} | ||
To learn how to leverage [[Parser Functions]], [[Lua]] programming language/[[Scribunto]] in MediaWiki, see [[Demo:CodeWrapper|Demo:CodeWrapper]]. | |||
=More Comprehensive Guides= | =More Comprehensive Guides= | ||
MediaWiki's allows some mixture of HTML syntax and extension defined syntax to enable more functionalities. For additional coding syntax instruction, see the following links. | |||
#[[mw:Help:Formatting|MediaWiki Syntax]] | #[[mw:Help:Formatting|MediaWiki Syntax]] | ||
#[[mw:Help:Cite|Citation]] | #[[mw:Help:Link|MediaWiki Link]] | ||
#[[mw:Help:Cite|MediaWiki Citation]] | |||
#[[Semantic MediaWiki]] |
Latest revision as of 14:49, 18 May 2022
Absolute Essential
The essential markdown syntax for MediaWiki are:
- Hierarchical Markdown: use =
- Hyperlink: use [ and ]
- Transclusion: use { and }
They are essential because they formally define the structure of a hyperlinked document space.
Hierarchical Markdown
Use a number of balanced equal signs (=) to format the level of section titles. Larger number of equal signs indicates lower level.
Text Input | Rendered Result |
---|---|
=Level1= |
Level1 |
==Level2== |
Level2 |
===Level3=== |
Level3 |
====Level4==== |
Level4 |
Hyperlink to other pages
Terminology | Text Input | Rendered Result |
---|---|---|
Local Hyperlink | [[Main Page]] | Main Page |
External Hyperlink | [http://wikimedia.org wikimedia website] | wikimedia website |
Piped Link | [[Main Page|This is called the Piped Link]] | This is called the Piped Link |
Transclusion from other pages
Types of Transclusion | Sample Text Input | Rendered Result | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
locally defined page transclusion | {{:Paper/Algebra of Systems}} | Koo, Hsueh-Yung Benjamin; Simmons, Willard; Crawley, Edward (Nov 16, 2021). "Algebra of Systems as a Meta Language for Model Synthesis and Analysis" (PDF). local page: IEEE TRANSACTIONS ON SYSTEMS, MAN, AND CYBERNETICS.
| |||||||||||||||||
transcluding template page | {{LogicModel}} |
| |||||||||||||||||
function invocation | {{#invoke:Utility|monthNumberToFullMonthName |{{CURRENTMONTH}}}} | November |
To learn how to leverage Parser Functions, Lua programming language/Scribunto in MediaWiki, see Demo:CodeWrapper.
More Comprehensive Guides
MediaWiki's allows some mixture of HTML syntax and extension defined syntax to enable more functionalities. For additional coding syntax instruction, see the following links.