Template talk:UpdatedDYK

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Suggestion for improvement[edit]

This template contains two wikilinked dates that get placed on DYK user pages, ex: "On [[30 December]], [[2008]], ..." and "<!-- [[{{CURRENTMONTHNAME}} {{CURRENTDAY}}]], [[{{CURRENTYEAR}}]] -->." There have been several recent discussions with consensus on WP:MOSNUM that dates should no longer be linked. See the WP:MOSNUM#Linking and autoformatting of dates guideline in particular. So perhaps it's time to delink the dates in this template. Rather than just delinking the dates, it might be useful to include a link to the DYK archive page where this DYK will reside so that people can find it easily in the future. Something similar to what is already done on {{DYKtalk}} and {{ArticleHistory}}. Could someone with the expertise to do that please comment. Thanks. Truthanado (talk) 16:15, 31 December 2008 (UTC)[reply]

Actually link...[edit]

Instead of explaining how to see the page views, why not actually provide a link directly? Majorly talk 18:51, 8 October 2009 (UTC)[reply]

I guess it could be doable with {{BASEPAGENAME}} and {{subst:CURRENTMONTH}} or some such. But one problem is, at the time the tag is placed on the article, a direct link would be useless (it takes 24 hours for the stats to be available) and may even be broken (sometimes at the beginning of the month, there isn't even a link yet for that month anyway). rʨanaɢ talk/contribs 20:42, 8 October 2009 (UTC)[reply]
It's just as useless informing the user how to go about doing it if they are unable to for a day. We might as well link to it directly, instead of providing a link explaining how to find it. And using magic words would work - it works on page history, so I've no reason to doubt it would be a problem here. Majorly talk 20:56, 8 October 2009 (UTC)[reply]
I can try to fiddle with it; it would have to essentially use
http://stats.grok.se/en/ + {{subst:CURRENTYEAR}}{{subst:CURRENTMONTH}} / {{{article}}}
Things just will get messy because I'm not sure how magicwords within urls work; normally this is best done with something like {{fullurl}} but I don't think there's anything like that for the stats or toolserver pages. I'll have to test it out a bit. rʨanaɢ talk/contribs 21:20, 8 October 2009 (UTC)[reply]
You'd have to use urlencode on the article name: {{urlencode:{{{article}}}}}. Shubinator (talk) 00:55, 9 October 2009 (UTC)[reply]
I tried

[http://stats.grok.se/en/{{urlencode:{{subst:CURRENTYEAR}}{{subst:CURRENTMONTH}}}}/{{urlencode:{{subst:BASEPAGENAME}}}} pageview stats]

on Talk:Not One Less. But it doesn't quite work; {urlencode} seems to turn the spaces into + instead of _ . Seems to work correclty with {anchorencode}, though, leaving the final code at

[http://stats.grok.se/en/{{urlencode:{{subst:CURRENTYEAR}}{{subst:CURRENTMONTH}}}}/{{anchorencode:{{subst:BASEPAGENAME}}}} pageview stats]

Do you think it will be ok to try updating the template for a test run? My suggestion would be to keep the other link as well, perhaps as a question mark or "info" or whatever, resulting in a box like this:
Updated DYK query On [[Wikipedia:Recent_additions#{{{1}}} {{{2}}}|{{{1}}}, {{{2}}}]], Did you know? was updated with a fact from the article [[{{{3}}}]], which you created or substantially expanded. You are welcome to check how many hits your article got while on the front page (see the pageview stats (?)) and add it to DYKSTATS if it got over 5,000. If you know of another interesting fact from a recently created article, then please suggest it on the Did you know? talk page.
Note that the link in the example here won't work, since the pageview link in the template will only work for pages in article space (which is all we want anyway). rʨanaɢ talk/contribs 01:42, 9 October 2009 (UTC)[reply]
Oh, and another thing I just realized: currently, if credit is given for multiple articles, this will only link to the pageview stats for the first page. But I don't know if people are even putting multiple articles in this template anyway. rʨanaɢ talk/contribs 01:48, 9 October 2009 (UTC)[reply]
Ok, we'll see how it works. The bot gives an individual credit for every article, so that's fine. Shubinator (talk) 02:17, 9 October 2009 (UTC)[reply]

(out) Just checked the bot's run. The pageview stats link appears to be broken for article titles that include special characters or punctuation (such as commas and parentheses). See User talk:K731#DYK for Lasnamäe, User talk:Music2611#DYK for The Baby Shower (Seinfeld), and User talk:Hassocks5489/Archives/2009/October#DYK for St James the Less Church, Lancing. rʨanaɢ talk/contribs 11:34, 9 October 2009 (UTC)[reply]

Hmm, it doesn't like the urlencode. I fiddled with this for DYKHousekeepingBot, and the title can be copied & pasted (including spaces) into the stats.grok.se url, with two exceptions: % must be %25 and ? must be %3F. I don't think it's possible to do find+replace with templates though. Shubinator (talk) 03:42, 10 October 2009 (UTC)[reply]
Yeah, a lot of the toolserver urls work with spaces (ie, if you paste a title with spaces directly into the address bar). The problem, though, is the link that displays in the text: if the pagename is put in with spaces (ie, if we just use {{{article}}} directly instead of urlencoding it), it messes up. For instance, typing
http://stats.grok.se/en/200910/The Baby Shower (Seinfeld)
directly into the address bar works fine (it seems to magically turn each space into %20, because that's what you get if you copy and paste the url out of the address bar after the page has loaded). But if you try to use that for an inline link here, like
[http://stats.grok.se/en/200910/{{{article}}} pageview stats]
where {{{article}}} is "The Baby Shower (Seinfeld)", you get:
Baby Shower (Seinfeld) pageview stats
rʨanaɢ talk/contribs 18:39, 10 October 2009 (UTC)[reply]
Hmm, it's the wiki syntax kicking in. Replacing the spaces with underscores works. Shubinator (talk) 01:17, 11 October 2009 (UTC)[reply]
Yeah, {anchorencode} does that. But the problem is the punctuation and special characters, those are what broke in the ones linked above. rʨanaɢ talk/contribs 14:25, 11 October 2009 (UTC)[reply]

Being Bold[edit]

Its my intention to change the "?" logo to a Halloween logo in the next hour and leave it that way for next 24 hours or so. That way Halloween DYK contributors will get a slightly different holiday "thank you"... Victuallers (talk) 18:44, 30 October 2009 (UTC)[reply]

That sounds good. Although, I think Shubinator made special templates just for the April Fool's DYKs, so maybe there is something like that for Halloween as well. You might want to check with him. rʨanaɢ talk/contribs 18:52, 30 October 2009 (UTC)[reply]
I just made the April Fool's one. I like the demon face, it's a nice touch. Shubinator (talk) 06:52, 1 November 2009 (UTC)[reply]
Noting this has been set up for every year. Rcsprinter (orate) @ 00:32, 1 November 2012 (UTC)[reply]

 You are invited to join the discussion at User talk:Shubinator § Getting DYKUpdateBot to use the action parameter. {{u|Sdkb}}talk 20:40, 28 September 2023 (UTC)[reply]