Inline Templates | ||||
|
This template and the similar ((Subscription)) should probably have the same style. See the comment on that template's talk page. —Mrwojo (talk) 01:24, 8 November 2009 (UTC)
If anyone is having trouble understanding the instructions and examples I've tried to clarify a bit more here: Wikipedia talk:WikiProject Inline Templates#Template:Registration required/doc. -- Ϫ 09:36, 14 February 2011 (UTC)
(quoting the current template documentation) "Append this template directly after the external link or citation template, leaving the original link intact."
Does this mean "external link template or citation template"? More likely to me, this tag is intended for use with external links that are formed manually, either "within a paragraph" (mentioned earlier in the documentation) or within a bulleted list entry (not mentioned).
The documentation should mention bulleted list entries, perhaps specifically mention the standard External links section. It should illustrate such use of the template (as in documentation of ((subscription required))) and also some commendable use "within a paragraph".
--P64 (talk) 19:57, 13 February 2013 (UTC)
<ref>[http://www.example.com/ Example]((registration required))</ref> <ref>((cite web |url=http://www.example.com/ |title=Example ))((registration required))</ref>
*[http://www.example.com/ Example]((registration required)) *((cite web |url=http://www.example.com/ |title=Example ))((registration required))
Would it be possible to add a "via" parameter to this template, comparable to the via parameter in the subscription template? We who have recently been given JSTOR accounts (see WP:JSTOR for more) would like to be able to indicate that articles can be accessed via that repository, and that it requires users to register before giving access. Currently, we're using the subscription template, but (since articles are available for free to those who register), it's not really the correct one to be using! Thanks, MeegsC (talk) 19:34, 18 September 2014 (UTC)
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Per above requests. It's been years since I installed and was sysadmin of a Wikimedia instance at work, but this is something easy.
I was unable to view, let alone edit, the registration required template code as it is unaccountably in full template protection mode, so I hope this edit request template gets attention to this long-outstanding issue. (The first request on this Talk page, for a change to exactly match the subscription required template's styling - or sensible lack thereof, was made in 2009.)
To fulfill two reasonable requests at once, it would be simplest and surest to literally copy the subscription required code and: 1) replace 2 words in the 10 short lines of code; 2) add 1 needed tracking category; and 3) substitute 2 tracking categories. Takes longer to explain than to actually do and I would if I had the power to do so. Took me just a few minutes to work out. Then just save as a much improved registration required template, with no loss of past functionality and no untested transclusion headaches. All pre-tested by robust subscription required code in use on over 100,000 pages.
I made all of 4 obvious text substitutions: 2 each of "Registration" for "Subscription" (lines 3 & 7) and "registration" for "subscription" (lines 4 & 8).
The 2 lines (5 & 10) including a page in one of two subscription-specific tracking categories require the substitution of 2 registration-specific tracking categories: 1) for use without via parameter (that category already exists) and 2) for use with via, a new (old? borrowed?;) tracking category.
I suggest:
(Note to anyone trying to follow this, but not seeing the tracking categories: they are "hidden" from normal page view and can be viewed by checking "Show hidden categories" on your Special:Preferences#mw-prefsection-rendering page. Then visit Wikipedia:JSTOR#Citation to see all three that are currently in use, 2 for subscription required (with via and without) and 1 for registration required. Don't delete them! They are placed there by these two templates, either in standalone mode or when called on ("transcluded") from use within the cite or citation templates.)
To make the above crystal clear, I've copied the subscription required template code below, minus some curly brackets, etc. (to avoid code execution; nowiki doesn't work on template code well) and showing only my 6 short text substitutions here, to make the simplicity of my respectfully repeated request obvious to all.
1. if: via – via via link note|note=((#switch: 1|not-sentence 2. | s 3. | sentence = Registration required. 4. | registration required 5. (Category:Pages containing links to registration-only content using via)|((link note|note=((#switch: (({1|not-sentence))} 6. | s 7. | sentence = Registration required. 8. | registration required 9. (closing brackets) 10. includeonly (Category:Pages containing links to registration-only content) includeonly noinclude documentation noinclude
View (click Edit, but don't try to change (sensibly) semi-protected template code) original source here: ((subscription required))
Admin(s)/Maintainer(s): Can this be done? If not, can you please explain why not? If it can be done, will you please do it? ;)
As an added courtesy, please make the fully-protected code page semi-protected, for code review purposes and alignment with subscription required template. Thank you for your attention. -- Paulscrawl (talk) 23:26, 5 October 2014 (UTC)
@Redrose64:Thank you for those pointers. It's been a long time since I edited Wikimedia templates and this will be my first for Wikipedia. Been meaning to learn this process. Testcases doc makes sense.
BTW, I did click "View source" when this template was in fully-protected mode and all I saw above the fold was the whitespace surrounding the full screen description of protection level, not the requested view of code (below fold). Can't replicate now - no matter, but a navlink (template page URL plus &action=edit, with link text "You may view or copy this code.") would be good to see top and center. Best right after text, "This page is currently protected so that only template editors and administrators can edit it." in box containing lock icon. Better UI, tone, and good fallback mode for lost users.
I'll sandbox this template later today, adding test cases and revised documentation as I go. Thanks again. -- Paulscrawl (talk) 09:31, 6 October 2014 (UTC)
|via=
is supplied, and a different one if not. I just want to point out that this differs from the behavior of the ((Subscription required))
template. That template always assigns the category Category:Pages containing links to subscription-only content. If |via=
is supplied, then the page is additionally assigned to Category:Subscription required using via.|via=
is supplied, the new category Category:Registration required using via should also be included.@MeegsC:, I think it's done, including tests. Template:Registration required/sandbox Template:Registration required/testcases Need to copy & edit doc from Template:Subscription_required (as the whole point of this exercise is absolutely identical functionality for Template:Registration required) and edit to fit, retaining only redirects and other pertinent stuff from current doc for registration required. I'll get to that shortly, once I know where to put it without trampling on current doc or creating more work than need be when time to switchover to new and improved and tested template.
I wasn't clear if draft for doc goes in subpage for sandbox or testcases or where. @Grolltech:, could you please take a look and advise? I followed your suggestion on Category:Registration required using via - thank you for that. Paulscrawl (talk) 06:27, 10 December 2014 (UTC)
((Registration required/sandbox))
:
<noinclude>
((template sandbox notice))
</noinclude>
((Registration required))
template with this code:
<noinclude>
((documentation))
</noinclude>
((Registration required/sandbox/doc))
subpage by clicking that red link. You can then display your new and improved documentation at the bottom of the sandbox, by instead coding:
<noinclude>
((template sandbox notice))
((documentation))
</noinclude>
((Registration required/testcases))
page appears in the list, as expected. Because that is a hidden category, you'll only see it on the testcases page itself if your user preference 'Show hidden categories' is checked under "Advanced options". Good work! —grolltech(talk) 13:04, 20 December 2014 (UTC)An issue involving this template is discussed at Wikipedia:Village pump (technical)#CATEGORY:PAGES WITH LOGIN REQUIRED REFERENCES OR SOURCES. PrimeHunter (talk) 03:30, 4 May 2015 (UTC)