The Kunena team has announce the arrival of Kunena 7.0.4 [K 7.0.4] in stable which is now available for download as a native Joomla extension for J! 5.4.x/6.0.x. This version addresses most of the issues that were discovered in K 6.2 / K 6.3 / K 6.4 and issues discovered during the last development stages of K 7.0
Question
no attachment icon in thread view if attachment is not on first post?
$database->setQuery("SELECT mesid FROM #__fb_attachments WHERE mesid=$leaf->id");
$attachmentsicon = $database->loadResult();
later it tests for nonzero value on $attachmentsicon to add the icon.
Please can someone help me as to what query could find if there are any attachments in the entire thread, rather than just on the root post? Knowing this would help a long way to making some useful modules I could share.
Something like this could help (returns count of attachments in the thread):
$database->setQuery("SELECT count(*) FROM #__fb_attachments WHERE mesid IN (SELECT id FROM #__fb_messages WHERE thread=$leaf->id OR id=$leaf->id)");
$attachmentcount = $database->loadResult();