Template:Short description
From Chalo Chatu, Zambia online encyclopedia
<templatestyles src="Module:Documentation/styles.css"></templatestyles>
Template:Short description
This template sets a page’s short description. On Chalo Chatu it is implemented as a wrapper around the SHORTDESC magic word. It supports a minimal, safe usage to avoid expression-parser errors.
Usage
Basic form:
{{Short description|Your short description here}}
Disable on a page:
{{Short description|none}}
Optional second parameter (if supported on your build) to prevent replacement:
{{Short description|Your text here|noreplace}}
Parameters
- 1
- The short description text. Required unless set to "none".
- 2
- Optional. Pass "noreplace" to avoid overwriting an existing short description if your build supports it.
- notes
- This documentation covers the **baseline** template with no HTML output to prevent the error: Expression error: Unexpected < operator.
Examples
- Standard page
{{Short description|Zambia’s national encyclopedia}}
- Disable short description
{{Short description|none}}
Best practices
- Keep descriptions concise (about 40–90 characters).
- Avoid wikilinks, templates, or markup inside the description.
- Use sentence case, no terminal period.
Troubleshooting
- Error
- Expression error: Unexpected < operator.
- Cause: Another template or parser function is evaluating HTML as part of an expression.
- Fix: Use the no-HTML baseline version of this template (as currently deployed). Do not add raw HTML, categories, or invokes inside this template. If the error persists, test with only:
{{Short description|Test}}
If that works, the fault is elsewhere on the page.
- SHORTDESC not supported
- If your wiki build does not support the SHORTDESC magic word, comment out the line in the template that calls it. The template will still parse without setting the description.
See also
- Help:Short description (local help page, if available)
- Template:Short description/sandbox – for experiments
- Template:Short description/testcases – for regression tests
TemplateData
Sets or disables a page's short description using the SHORTDESC magic word. Minimal, no-HTML version for maximal compatibility.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Short description | 1 | The short description text. Use 'none' to disable on the page. | String | optional |
noreplace | 2 | If set to 'noreplace', will not overwrite an existing short description (only if supported by your build).
| String | optional |