| Status: | effective |
| Progress: | 100% |
| Version: | 3.1.0+ |
Links in values
This help page on links in values describes the possibility to add links using wikitext like e.g. [[...]] (internal links) or [...] (external links) or even an annotation [[Property::Property value]] within the property values added/annotated to datatype "Text"Holds text of arbitrary length with in-text annotations.
| Table of Contents | |
|---|---|
Important notes
- By default, it is impossible to do this, and the property value will not be added to the property. In must be enabled for the wiki with configuration parameter
$smwgParserFeaturesSets the behaviour of features related to text and annotation parsing (SMW ≥ 3.0.0) or configuration parameter$smwgLinksInValuesSets whether internal links in values for properties of datatype "Text" may be stored within property values (SWM ≤ 2.5.8) respectively. - When accessed the annotated values via browsing interfaces, e.g. special page "Browse"No description was provided. etc. the annotated links will not render as HTML.
Annotation examples
Data value containing an internal and external link
- Syntax
[[Has text::This text contains an internal link to the [[Main Page]] of this wiki and an external link to the [https://sandbox.semantic-mediawiki.org/wiki/Main_Page Main Page] of another wiki.]]
- Result
This text contains an internal link to the Semantic MediaWiki of this wiki and an external link to the Main Page of another wiki.
→ Annotation as seen with special page "Browse"
Data value containing an annotation
- Syntax
[[Has text::This text contains an annotated internal link to the [[Has page::Main Page]] of this wiki.]]
- Result
This text contains an annotated internal link to the Semantic MediaWiki of this wiki.
→ Annotation as seen with special page "Browse"
- Syntax
[[Has text::This text contains an annotated internal link to the [[Has page::Main Page]] of this wiki.|]]
- Result
This text contains an annotated internal link to the Semantic MediaWiki of this wiki.|
→ Annotation as seen with special page "Browse"
See also
- Help page on in-text annotation
- Help page on configuration parameter
$smwgParserFeaturesSets the behaviour of features related to text and annotation parsing (SMW ≥ 3.0.0) or configuration parameter$smwgLinksInValuesSets whether internal links in values for properties of datatype "Text" may be stored within property values (SWM ≤ 2.5.8) - Demo page on links in values - Describes a pre Semantic MediaWiki 2.5.0 workaround using the parser function
#setavoiding to enable links in values via configuration.
References
- ^ Semantic MediaWiki: GitHub pull request gh:smw:2153
- ^ Semantic MediaWiki: GitHub pull request gh:smw:3674