User talk:Lucario: Difference between revisions

m
no edit summary
mNo edit summary
mNo edit summary
Line 38: Line 38:
=== Currenttimestamp? ===
=== 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)
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)


== Time refresh on page load test ==
== Time refresh on page load test ==
Line 45: Line 47:
* expecting empty #var:trololo default: <code>{{#var:trololo|{{CURRENTTIMESTAMP}}}}</code>
* expecting empty #var:trololo default: <code>{{#var:trololo|{{CURRENTTIMESTAMP}}}}</code>
* expecting defined #var:trololo: <code>{{#vardefine:trololo|{{CURRENTTIMESTAMP}}}}{{#var:trololo}}</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==
6,576

edits