User talk:Lucario: Difference between revisions

Jump to navigation Jump to search
m
(24 intermediate revisions by 3 users not shown)
Line 1: Line 1:
=== Currenttimestamp? ===
As far as I can see, the CURRENTTIMESTAMP template (i.e. {{CURRENTTIMESTAMP}}) doesn't update per page refresh, it seems to stay stuck at the point when the last edit occurred or the cache page was generated. So I'm not sure it can be used to generate the random value. I think we had determined that some JavaScript is needed to either handle the random selection, or minimally generate an actual random value here. BTW, a parameterless version of things would be nicer, even if it can't handle the random selection. [[User:Kolano|Kolano]] ([[User talk:Kolano|talk]]) 08:42, 27 January 2018 (CET)
:You're right, it didn't update on page load. I was hoping that it was just cache of another template rather than on page directly, but nope it's still not updated, as confirmed in next section below. We'll look into Javascript I guess. I've wondered how will Javascript look and how will it pick three lucky videos and list the rest. I'm no Javascript expert so I won't be able to tell how hard it'd be. [[User:Lucario|Lucario]] ([[User talk:Lucario|talk]]) 09:00, 27 January 2018 (CET)
::You can't cheat the cache. You have to use [[MediaWiki:Common.js]]. That's the only way. If you put logic in there to generate a random seed, that should be enough. - [[User:Xerxes|Xerxes]] ([[User talk:Xerxes|talk]]) 09:15, 27 January 2018 (CET)
:::Thanks for letting me know, it kinda suck we've had to wait for the cache to purge out for the time to update. [[User:Lucario|Lucario]] ([[User talk:Lucario|talk]]) 14:18, 27 January 2018 (CET)
:I agree! Parameterless seems better. With it the uploader can just select all > copy'n'paste the url then append with caption. It'll have same feel as you'd copy full url then append with caption in brackets. There was one editor who deliberately assign +1 to all vid/cap parameters then use the first parameter for his video. It made me want to curl! [[User:Lucario|Lucario]] ([[User talk:Lucario|talk]]) 09:12, 27 January 2018 (CET)
:: Yes, they also frequently will perform arbitrary edits (i.e. adding/removing spacing) until their video comes to the top. This is the exact reason we want to restore true randomness. [[User:Kolano|Kolano]] ([[User talk:Kolano|talk]]) 09:32, 27 January 2018 (CET)
: Generating a random ID in common.js is easy enough. However, I'm not clear there is any way for that to hand off to wiki handling, so I think any randomization related logic here is likely pointless. Since I'm not clear there is any good way to perform a hand-off, I think we need to perform the random selection and HTML generation in JavaScript, which makes things more complicated (though not particularly difficult). [[User:Kolano|Kolano]] ([[User talk:Kolano|talk]]) 09:37, 27 January 2018 (CET)
:: I don't think I'll be around to do that stuff. Anyone else can try. [[User:Lucario|Lucario]] ([[User talk:Lucario|talk]]) 14:18, 27 January 2018 (CET)
== Time refresh on page load test ==
* current time: <code>{{CURRENTTIMESTAMP}}</code>
* current time in template: <code>{{vgrelease|NA={{CURRENTTIMESTAMP}}}}</code>
* expecting empty #var:trololo: <code>{{#var:trololo}}</code>
* expecting empty #var:trololo default: <code>{{#var:trololo|{{CURRENTTIMESTAMP}}}}</code>
* expecting defined #var:trololo: <code>{{#vardefine:trololo|{{CURRENTTIMESTAMP}}}}{{#var:trololo}}</code>
Which one updates faster?
:{{CURRENTTIMESTAMP}}
:{{#time:U}}
:{{#time:z}}
== SNES Ratings==
== SNES Ratings==
Did you actually test the SNES titles, a number of the pre-existing ratings indicated problems so I'm not clear it's safe to assume them to all be 5 stars. [[User:Kolano|Kolano]] ([[User talk:Kolano|talk]]) 03:15, 30 March 2017 (CEST)
Did you actually test the SNES titles, a number of the pre-existing ratings indicated problems so I'm not clear it's safe to assume them to all be 5 stars. [[User:Kolano|Kolano]] ([[User talk:Kolano|talk]]) 03:15, 30 March 2017 (CEST)
6,576

edits

Navigation menu