// array with html for each thread (parent+comments)
- $treads = array();
- $treadsid = -1;
+ $threads = array();
+ $threadsid = -1;
if(count($items)) {
$tpl = get_markup_template('search_item.tpl');
foreach($items as $item) {
- $treadsid++;
+ $threadsid++;
$comment = '';
$owner_url = '';
$arr = array('item' => $item, 'output' => $tmp_item);
call_hooks('display_item', $arr);
- $treads[$treadsid] .= $arr['output'];
+ $threads[$threadsid] .= $arr['output'];
}
$comments_seen = 0;
$comments_collapsed = false;
- $treadsid++;
- $treads[$treadsid] = "";
+ $threadsid++;
+ $threads[$threadsid] = "";
}
else {
// prevent private email from leaking into public conversation
if(($comments[$item['parent']] > 2) && ($comments_seen <= ($comments[$item['parent']] - 2)) && ($item['gravity'] == 6)) {
if(! $comments_collapsed) {
- $treads[$treadsid] .= '<div class="ccollapse-wrapper fakelink" id="ccollapse-wrapper-' . $item['parent']
+ $threads[$threadsid] .= '<div class="ccollapse-wrapper fakelink" id="ccollapse-wrapper-' . $item['parent']
. '" onclick="openClose(' . '\'ccollapse-' . $item['parent'] . '\'); $(\'#ccollapse-wrapper-' . $item['parent'] . '\').hide();" >'
. sprintf( t('See all %d comments'), $comments[$item['parent']]) . '</div>'
. '<div class="ccollapse" id="ccollapse-' . $item['parent'] . '" style="display: none;" >';
}
}
if(($comments[$item['parent']] > 2) && ($comments_seen == ($comments[$item['parent']] - 1))) {
- $treads[$treadsid] .= '</div>';
+ $threads[$threadsid] .= '</div>';
}
$redirect_url = $a->get_baseurl() . '/redir/' . $item['cid'] ;
$arr = array('item' => $item, 'output' => $tmp_item);
call_hooks('display_item', $arr);
- $treads[$treadsid] .= $arr['output'];
+ $threads[$threadsid] .= $arr['output'];
}
}
}
// if author collapsing is in force but didn't get closed, close it off now.
/*if($blowhard_count >= 3)
- $treads[$treadsid] .= '</div>';*/
+ $threads[$threadsid] .= '</div>';*/
$page_template = get_markup_template("conversation.tpl");
$o .= replace_macros($page_template, array(
- '$treads' => $treads,
+ '$threads' => $threads,
'$dropping' => ($dropping?t('Delete Selected Items'):False),
));