Difference between revisions of "Template:Q"

From Data JW United
Jump to navigation Jump to search
Line 8: Line 8:
  
 
= One question - one paragraph =
 
= One question - one paragraph =
== Usage ==
+
<code><nowiki>{{q|25|Isn't this nice?}}</nowiki></code><br>
<code><nowiki>{{q|25|Isn't this nice?}}</nowiki></code>
 
=== Example action ===
 
 
It will automatically link the question to the 25 paragraph.
 
It will automatically link the question to the 25 paragraph.
 
= One question - multiple paragraphs =
 
= One question - multiple paragraphs =
Comming soon ...
+
<code><nowiki>{{q|25-27|Isn't this nice?}}</nowiki></code><br>
 +
It will automatically link the question to the 25 paragraph.
  
 
= Tests =
 
= Tests =

Revision as of 18:26, 12 April 2020

q - stands for Question
This template is recommended to be used whenever a literature question is needed.

Parameters

first - number of the question.
second - the actual text of the question.

One question - one paragraph

{{q|25|Isn't this nice?}}
It will automatically link the question to the 25 paragraph.

One question - multiple paragraphs

{{q|25-27|Isn't this nice?}}
It will automatically link the question to the 25 paragraph.

Tests

One question - one paragraph

Code:
{{q|25|Isn't this nice?}}

Expected:

Actual:

One question - multiple paragraphs

Number of first paragraph of one digit

Code:
{{q|7-10|Isn't this nice?}}

Expected:

Actual: