From: Zach Copley Date: Mon, 18 Apr 2011 20:53:14 +0000 (-0700) Subject: Add a 'closed' class to questions that have been closed X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=5721bb146a4c78b34f6fc814c500803cdb306b07;p=quix0rs-gnu-social.git Add a 'closed' class to questions that have been closed --- diff --git a/plugins/QnA/QnAPlugin.php b/plugins/QnA/QnAPlugin.php index 6841ec9873..ad0541a71c 100644 --- a/plugins/QnA/QnAPlugin.php +++ b/plugins/QnA/QnAPlugin.php @@ -299,6 +299,13 @@ class QnAPlugin extends MicroAppPlugin if ($nli->notice->scope != 0 && $nli->notice->scope != 1) { $class .= ' limited-scope'; } + + $question = QnA_Question::staticGet('uri', $nli->notice->uri); + + if (!empty($question->closed)) { + $class .= ' closed'; + } + $nli->out->elementStart( 'li', array( 'class' => $class,