Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2012-10-04 16:17:58

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,356
GitHub

"Comments will be open until x"

Hi.
I’d like to add a closing date to my comment form, along the lines of Comments can be submitted until Dec 14th, 2012. The date would be applied using comment_form and be the article posted timestamp plus the comments_disabled_after value (6 weeks in my case). The result should ideally be formatted using strftime.

I don’t have the smarts to figure this out entirely, but my thinking is along the lines of:

  • set posted as a variable
  • use php to apply strtotime ("+6 weeks" ) to the variable and then echo it
  • something fancy involving strftime

Any pointers or guidance is gratefully received.

Thank you in advance.

Offline

Board footer

Powered by FluxBB