Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.

What is wrong with this bit of code because I can't select an answer as the best?

+1 vote
asked Aug 26, 2014 in Themes by gold.developer
edited Aug 26, 2014 by gold.developer

I was trying to select an answer as correct and I realised that I can't, when I click to select one it shows up the loading symbol and then nothing happens, I realised that this problem is from this bit of code, but I only don't know what's the problem and also don't know how to fix it


if ($a_item['hidden'])
$this->output('<DIV CLASS="qa-a-item-hidden">');
elseif ($a_item['selected'])
$this->output('<DIV CLASS="qa-a-item-selected">');
$this->post_meta($a_item, 'qa-a-item');
if ($a_item['hidden'] || $a_item['selected'])
Or maybe it's in this code below which is above of this first one
function a_list_item($a_item)
$extraclass=@$a_item['classes'].($a_item['hidden'] ? ' qa-a-list-item-hidden' : ($a_item['selected'] ? ' qa-a-list-item-selected' : ''));
$this->output('<DIV CLASS="qa-a-list-item '.$extraclass.'" '.@$a_item['tags'].'>');
$this->output('<DIV CLASS="qa-q-view-stats">');
$this->post_avatar($a_item, 'qa-a-item');
$this->output('</DIV> <!-- END qa-a-list-item -->', '');


Q2A version: 1.6.3

1 Answer

0 votes
answered Aug 27, 2014 by vevion
Maybe your theme isn't working with 1.6.3 or there's some code (jquery, html) missing.