To help centralise discussions and keep related topics together, the following pages redirect here: |
Template:Fraction is permanently
protected from editing because it is a
heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by
consensus, editors may use {{
edit template-protected}} to notify an administrator or template editor to make the requested edit. Usually, any contributor may edit the template's
documentation to add usage notes or
categories.
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases. |
This template ( Template:Frac) was considered for deletion on 1 June 2010. The result of the discussion was "keep". |
|
||
This page has archives. Sections older than 90 days may be automatically archived by Lowercase sigmabot III when more than 4 sections are present. |
Comment: I was unaware of the fore mentioned move until I noticed
The Naked Gun film series article had fraction display issues (see its
talk page discussion). Template {{
Frac}} does not function the same since I last used it. Previously, I could display 331⁄3 by putting the whole number inside {{Frac|33|1|3}}
, or outside 33{{Frac|1|3}}
the template. Apparently, this has changed, and whole numbers must go outside the template, otherwise a plus sign +
appears in the middle of the fraction. I have adjusted the documentation to reflect this change. —
CJDOS, Sheridan, OR (
talk)
07:26, 9 August 2021 (UTC)
{{Reply to|Johnuniq}}
should work. In any case, in the talk page for
The Naked Gun, I said "in this edit" with a link to the
edit history. That precise link is the first edit I performed after noticing a problem. As mentioned, {{Frac|33|1|3}}
should produce the expected output, but it's been quite a while since I last used it (no idea how long ago, but probably sometime this year). Instead, it sticks a plus sign +
in the middle of the fraction. This is demonstrated in my edit link, because {{
Main}} under each of the
§ Films subheadings adds a plus sign (maybe this should be expected when the templates are nested; another editor had done this before I spotted it), but further down in
§ Main characters, it does it to one of bullet points (O. J. Simpson), and further down still, it does it in the
§ Reception tables (note, the preceding § links will open the specified page history, not the article as it is now).''[[Naked Gun 33 1/3: The Final Insult|Naked Gun {{frac|33|1|3}}: The Final Insult]]''
) which causes a redirect to ''[[Naked Gun 33⅓: The Final Insult]]''
, the ASCII fraction. So, I had replaced several instances of the backslash fraction with ASCII. I have in the past included the Integer within {{
Frac}} without issue (as per the template's doc). As the plus sign +
did not initially appear, I did not expect it to appear when replacing a forward slash fraction with an ASCII fraction... but as you can see from the page history, it showed up.+
in the fractions. It still wasn't 100% right, as {{
Frac}} nested within {{
Main}} was displaying a forward slash fraction, rather than the expected output; an IP editor corrected this after me by replacing {{
Frac}} within {{
Main}} with ASCII.+
. That's all I'm trying to say—I only meant to report the issue. Does the documentation require clarification about where
Template:Frac should not be implemented? —
CJDOS, Sheridan, OR (
talk)
06:28, 10 August 2021 (UTC)
{{frac|2|1|2}}
that produced 2+1⁄2 rather than using Unicode characters. I see that the articles are titled with Unicode:
The Naked Gun 2½: The Smell of Fear and
Naked Gun 33⅓: The Final Insult. It might be best to put up with the fact that the typography is not brilliantly clear because it's the best that can be achieved in wikitext. Being consistent with the article titles seems desirable. I was confused by the link you gave earlier because it has examples of {{frac}} being removed near the start. Thanks for the report but I don't think anything is going to change in the template because those problems are a side-effect of using
WP:TemplateStyles and probably should be worked around. Regarding whether the documentation should be updated to say when not to use the template, that would be desirable. See other reports on this page. The template shows 33+1/3 (using a vinculum instead of a slash) when the template knows the 33 is the integer portion of the number—the + suggests the value is the sum of 33 and one third. Copying the displayed fraction in your browser copies the +. A successful ping requires a new message and a new signature. Editing an existing message does not generate a notification.
Johnuniq (
talk)
07:46, 10 August 2021 (UTC)
@ Johnuniq: This has become a problem again because per Talk:Naked_Gun 33 1/3: The Final Insult#Requested move 12 July 2022, it was established that the Unicode character ⅓ is not safe for screen readers. The article was moved to Naked Gun 33 1/3: The Final Insult with a DISPLAYTITLE to make it use superscripts and subscripts. I have been using {{ frac}} to make the display text for links to this article, resulting in the unwanted "+". Sudiani reverted one of these, complaining about the "+" ( see diff). I was hoping the template could be fixed to eliminate the "+" or otherwise handle links better. Is that possible? If not, should I just redo all those links to use the actual title with "33 1/3"? -- Beland ( talk) 18:29, 22 July 2022 (UTC)
[[Example|{{frac|33|1|3}}]]
{{frac|33|1|3}}
{{frac|33|1|3}}
[[Example|{{frac|33|1|3}}]]
<templatestyles src="Fraction/styles.css"/>[[Example|{{frac|33|1|3}}]]
Thank you,
Johnuniq. As a followup, I recently performed a test regarding fractions in section headings, due issues with the
Floppy disk article. I will recreate the test as subsections below, to demonstrate three two methods of displaying fractions in section headings, and how the links appear in an address bar...
=== Fraction heading test 1¼ ===
Address bar: /info/en/?search=Template_talk:Fraction#Fraction_heading_test_1%C2%BC
=== Fraction heading test 2<sup>1</sup>/<sub>2</sub> ===
Address bar: /info/en/?search=Template_talk:Fraction#Fraction_heading_test_21/2
— CJDOS, Sheridan, OR ( talk) 02:13, 12 November 2022 (UTC)
{{
Frac|3|3|4}}
isn't permitted (template transclusion). I have
commented out said section here. —
CJDOS, Sheridan, OR (
talk)
05:54, 13 November 2022 (UTC)I have noted the workaround "33 {{frac|1|3}}". -- Beland ( talk) 02:24, 15 August 2023 (UTC)
This
edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Could the first line be split for readability of the template structure? That is, please replace the first line
<templatestyles src="Fraction/styles.css" /><span class="frac">{{#if:{{{3|}}}<!-- if 3
with
<templatestyles src="Fraction/styles.css" /><span class="frac"><!--
-->{{#if:{{{3|}}}<!-- if 3
— Quondum 20:28, 14 January 2024 (UTC)
Why does the Documentation section say "the optional integer (may be signed)" when it appears that all three arguments can be given a sign (which is displayed as expected)? Spel-Punc-Gram ( talk) 22:45, 18 April 2024 (UTC)
{{fraction|this|is|{{pi}}}}
gives this+is⁄π . Be careful not to confuse the intent of the template (what we want it to do) with the current implementation of the template (what it actually does at the moment that might change in the future).
Stepho
talk
23:00, 18 April 2024 (UTC)Okay, in 2024 are there really any browsers in use that can't display ½ or ¼? Can we make those fractions, at least, point to the characters? — Chowbok ☠ 02:27, 20 April 2024 (UTC)
To help centralise discussions and keep related topics together, the following pages redirect here: |
Template:Fraction is permanently
protected from editing because it is a
heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by
consensus, editors may use {{
edit template-protected}} to notify an administrator or template editor to make the requested edit. Usually, any contributor may edit the template's
documentation to add usage notes or
categories.
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases. |
This template ( Template:Frac) was considered for deletion on 1 June 2010. The result of the discussion was "keep". |
|
||
This page has archives. Sections older than 90 days may be automatically archived by Lowercase sigmabot III when more than 4 sections are present. |
Comment: I was unaware of the fore mentioned move until I noticed
The Naked Gun film series article had fraction display issues (see its
talk page discussion). Template {{
Frac}} does not function the same since I last used it. Previously, I could display 331⁄3 by putting the whole number inside {{Frac|33|1|3}}
, or outside 33{{Frac|1|3}}
the template. Apparently, this has changed, and whole numbers must go outside the template, otherwise a plus sign +
appears in the middle of the fraction. I have adjusted the documentation to reflect this change. —
CJDOS, Sheridan, OR (
talk)
07:26, 9 August 2021 (UTC)
{{Reply to|Johnuniq}}
should work. In any case, in the talk page for
The Naked Gun, I said "in this edit" with a link to the
edit history. That precise link is the first edit I performed after noticing a problem. As mentioned, {{Frac|33|1|3}}
should produce the expected output, but it's been quite a while since I last used it (no idea how long ago, but probably sometime this year). Instead, it sticks a plus sign +
in the middle of the fraction. This is demonstrated in my edit link, because {{
Main}} under each of the
§ Films subheadings adds a plus sign (maybe this should be expected when the templates are nested; another editor had done this before I spotted it), but further down in
§ Main characters, it does it to one of bullet points (O. J. Simpson), and further down still, it does it in the
§ Reception tables (note, the preceding § links will open the specified page history, not the article as it is now).''[[Naked Gun 33 1/3: The Final Insult|Naked Gun {{frac|33|1|3}}: The Final Insult]]''
) which causes a redirect to ''[[Naked Gun 33⅓: The Final Insult]]''
, the ASCII fraction. So, I had replaced several instances of the backslash fraction with ASCII. I have in the past included the Integer within {{
Frac}} without issue (as per the template's doc). As the plus sign +
did not initially appear, I did not expect it to appear when replacing a forward slash fraction with an ASCII fraction... but as you can see from the page history, it showed up.+
in the fractions. It still wasn't 100% right, as {{
Frac}} nested within {{
Main}} was displaying a forward slash fraction, rather than the expected output; an IP editor corrected this after me by replacing {{
Frac}} within {{
Main}} with ASCII.+
. That's all I'm trying to say—I only meant to report the issue. Does the documentation require clarification about where
Template:Frac should not be implemented? —
CJDOS, Sheridan, OR (
talk)
06:28, 10 August 2021 (UTC)
{{frac|2|1|2}}
that produced 2+1⁄2 rather than using Unicode characters. I see that the articles are titled with Unicode:
The Naked Gun 2½: The Smell of Fear and
Naked Gun 33⅓: The Final Insult. It might be best to put up with the fact that the typography is not brilliantly clear because it's the best that can be achieved in wikitext. Being consistent with the article titles seems desirable. I was confused by the link you gave earlier because it has examples of {{frac}} being removed near the start. Thanks for the report but I don't think anything is going to change in the template because those problems are a side-effect of using
WP:TemplateStyles and probably should be worked around. Regarding whether the documentation should be updated to say when not to use the template, that would be desirable. See other reports on this page. The template shows 33+1/3 (using a vinculum instead of a slash) when the template knows the 33 is the integer portion of the number—the + suggests the value is the sum of 33 and one third. Copying the displayed fraction in your browser copies the +. A successful ping requires a new message and a new signature. Editing an existing message does not generate a notification.
Johnuniq (
talk)
07:46, 10 August 2021 (UTC)
@ Johnuniq: This has become a problem again because per Talk:Naked_Gun 33 1/3: The Final Insult#Requested move 12 July 2022, it was established that the Unicode character ⅓ is not safe for screen readers. The article was moved to Naked Gun 33 1/3: The Final Insult with a DISPLAYTITLE to make it use superscripts and subscripts. I have been using {{ frac}} to make the display text for links to this article, resulting in the unwanted "+". Sudiani reverted one of these, complaining about the "+" ( see diff). I was hoping the template could be fixed to eliminate the "+" or otherwise handle links better. Is that possible? If not, should I just redo all those links to use the actual title with "33 1/3"? -- Beland ( talk) 18:29, 22 July 2022 (UTC)
[[Example|{{frac|33|1|3}}]]
{{frac|33|1|3}}
{{frac|33|1|3}}
[[Example|{{frac|33|1|3}}]]
<templatestyles src="Fraction/styles.css"/>[[Example|{{frac|33|1|3}}]]
Thank you,
Johnuniq. As a followup, I recently performed a test regarding fractions in section headings, due issues with the
Floppy disk article. I will recreate the test as subsections below, to demonstrate three two methods of displaying fractions in section headings, and how the links appear in an address bar...
=== Fraction heading test 1¼ ===
Address bar: /info/en/?search=Template_talk:Fraction#Fraction_heading_test_1%C2%BC
=== Fraction heading test 2<sup>1</sup>/<sub>2</sub> ===
Address bar: /info/en/?search=Template_talk:Fraction#Fraction_heading_test_21/2
— CJDOS, Sheridan, OR ( talk) 02:13, 12 November 2022 (UTC)
{{
Frac|3|3|4}}
isn't permitted (template transclusion). I have
commented out said section here. —
CJDOS, Sheridan, OR (
talk)
05:54, 13 November 2022 (UTC)I have noted the workaround "33 {{frac|1|3}}". -- Beland ( talk) 02:24, 15 August 2023 (UTC)
This
edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Could the first line be split for readability of the template structure? That is, please replace the first line
<templatestyles src="Fraction/styles.css" /><span class="frac">{{#if:{{{3|}}}<!-- if 3
with
<templatestyles src="Fraction/styles.css" /><span class="frac"><!--
-->{{#if:{{{3|}}}<!-- if 3
— Quondum 20:28, 14 January 2024 (UTC)
Why does the Documentation section say "the optional integer (may be signed)" when it appears that all three arguments can be given a sign (which is displayed as expected)? Spel-Punc-Gram ( talk) 22:45, 18 April 2024 (UTC)
{{fraction|this|is|{{pi}}}}
gives this+is⁄π . Be careful not to confuse the intent of the template (what we want it to do) with the current implementation of the template (what it actually does at the moment that might change in the future).
Stepho
talk
23:00, 18 April 2024 (UTC)Okay, in 2024 are there really any browsers in use that can't display ½ or ¼? Can we make those fractions, at least, point to the characters? — Chowbok ☠ 02:27, 20 April 2024 (UTC)