Add option to display date and time of original quoted post(s)

bzcomputers

Well-known member
Threads, especially when they are long and/or busy can have lots of quoted posts. Some quotes will seem odd and misplaced if they aren't qualified by when the original quoted post was made, this could possibly be days, weeks or even years before. Adding the date and time to the actual quote header can be very useful.

quote-date-time.webp
 
Upvote 9
Yep! Updoot it here:

1682865393251.webp

...as I just did. 😁

I think this might help members who are digging up old threads to reply to. We discourage it, and have auto-locked old threads, but sometimes staff reopens for whatever reason. 🤷‍♂️
 
I was also looking to add this, and one of the problems is that the quoted post does not carry over the time when the original post was created.

When you dump the variables inside the bb_code_tag_quote template, you notice the only fields carried over from the original post are:

Code:
"name" => PreEscaped {
  value: "original post username"
  ExcapeType: "html"
}

"source" => array:2 [
  "type" => "post"
  "id" => 1234567
]

"attributes" => array:2 [
  "post" => "1234567"
  "member" => "24680"
]

This source array should be also populated with the $post.post_date var that has the date of the original post that is being quoted.

I tried with <xf:include template="post_macros" /> inside the bb_code_tag_quote but it does not work.

It only brings the Unix zero time with date Jan 1, 1970, 00:00.

How can $post.post_id from the post_macros template be carried over to the bb_code_tag_quote template?
 
Last edited:
Back
Top Bottom