-2

Is there something I can set to show the dates and times that questions and comments were posted instead of vague time data like "2 days ago"?

As I typed this question, a link came up to a question where I learned that I can see the date and time by hovering the cursor over the vague time data. That's not as helpful as having the explicit date and time readily visible.

5
  • 7
    Why do you need to see the exact date/time readily visible? – user351483 Aug 7 '18 at 10:47
  • A lot of activity can occur on one day, or even one hour, all of which shows up as "n days/hours ago". With full timestamps, I could easily see what took place before or after what else. Having to hover the cursor makes this a tedious hunt. Full timestamps would make the information readily available with a quick glance. (But it seems that a lot of people didn't like me asking the question because it's been downvoted six times!) – NewSites Aug 7 '18 at 14:13
  • But things are normally sorted chronologically... – user351483 Aug 7 '18 at 14:15
  • I don't think that's true. It seems that answers are sorted by vote count. In any case, chronological sorting wouldn't help to see the timing between comments on different answers. – NewSites Aug 7 '18 at 17:21
  • 1
    Is this really such a bad question? The answer has been very helpful to me. I don't understand why the question has been downvoted so many times and the comment that asks why I asked it has been upvoted by about the same amount. – NewSites Aug 8 '18 at 14:46
2

I think the vague times with a more precise tooltip for the exceptions are best for most users...

But if you don't mind seeing the timestamp in the same format as the tooltip, you can use some custom CSS (just create a user stylesheet or userscript to add some custom CSS) to replace the regular timestamp text with the tooltip text.

All of the "vague" timestamps (from what I can tell, there may be some I missed) have a class of either relativetime or relativetime-clean and have the full timestamp in the title attribute. So you can do something like:

.relativetime,
.relativetime-clean {
    font-size: 0 !important; /* this hides the text without hiding the element itself */
}

.relativetime::after,
.relativetime-clean::after {
    content: attr(title);    /* this adds the content of the "title" attribute to the element */
    font-size: 12px;         /* re-set the font size so we can see the text... */
}

Which gives us this:

It's not perfect (it messes with some font sizes for example), but it's a start.

Unfortunately CSS can't format dates so if you want to display the timestamp in a different format you'll need to create a userscript and use JavaScript to format the timestamp.

6
  • Thank you Cai. I'd be interested in trying what you suggest, and it might give me exactly what I want, but I didn't know that I can have a CSS file that affects the appearance of websites I look at but don't control. Can you point me to information on how to implement such a CSS on my computer for Stack Exchange sites? (Also, please note that the box in your answer between "Which gives us this:" and "It's not perfect" is empty, at least on my computer.) – NewSites Aug 8 '18 at 1:16
  • @NewSites you can use an extension (e.g. this for Chrome), some other browsers will let you do it without any add-ons; how depends on your browser though so read through your browser's help or Google e.g. "how to add user stylesheet in [your browser]" – Cai Aug 8 '18 at 8:27
  • re the images, there has been some issues with imgur, that should be fixed now though – Cai Aug 8 '18 at 8:27
  • This is very cool. I researched the procedure for Firefox and wrapped your code in "@-moz-document domain(meta.stackexchange.com){...}". I had to delete the comments to get it to work. Also deleted the comma after ".relativetime-clean::after" because you don't have one after ".relativetime-clean". Result is that I now have the precise time showing (yay!), but the vague time is still also there. Is it possible "font-size: 0;" doesn't work in Firefox? (And your image is now visible. - Thank you.) – NewSites Aug 8 '18 at 13:34
  • @NewSites try adding !important to the font-size (I've just updated the code in my answer). Also good catch on the extra comma (that was a typo) and comments (they weren't standard CSS comments) – Cai Aug 8 '18 at 13:39
  • That did it! Also working on StackOverflow after adding ", domain(stackoverflow.com)" to wrapper. This is great; you have shown me how to customize the output of what I view on StackExchange, and maybe I'll have occasion to use such a trick in other contexts. Thank you! – NewSites Aug 8 '18 at 14:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .