Search results

Read more about Searching.

Searching for :


\n"; $hits_by_object = array(); $objects = array(); /* aggregate results by canonical object; since * we index comments separately from the top level * item, we need to adjust for that here */ foreach ($hits as $hit) { /* get canonical object */ list($item, $id) = explode(':', $hit->objectid, 3); $object = "$item:$id"; if (isset($hits_by_object[$object])) { if ($hit->score > $hits_by_object[$object]) { $hits_by_object[$object] = $hit->score; $objects[$object] = $hit; } } else { $hits_by_object[$object] = $hit->score; $objects[$object] = $hit; } } arsort($hits_by_object); ?> $score) { list($item, $id) = explode(':', $object, 2); $obj = $objects[$object]; $score = (int)($score * 100); $html = "\n"; echo $html; } echo "
$score%"; switch ($item) { case 'ticket': $tkt = MTrackIssue::loadByNSIdent($id); if ($tkt === null) { $tkt = MTrackIssue::loadById($id); } $aclid = "ticket:" . $tkt->tid; $html .= mtrack_ticket($tkt); if ($tkt->nsident) { $url = "{$ABSWEB}ticket.php/$tkt->nsident"; } else { $url = "{$ABSWEB}ticket.php/$id"; } $html .= " "; $html .= htmlentities($tkt->summary, ENT_QUOTES, 'utf-8'); $html .= ""; $html .= $obj->getExcerpt($tkt->description); break; case 'wiki': $wiki = new MTrack_Wiki_Item($id); $aclid = "wiki:$id"; $url = "{$ABSWEB}wiki.php/$id"; $html .= "". htmlentities($id, ENT_QUOTES, 'utf-8'). ""; $html .= $obj->getExcerpt($wiki->content); break; default: $aclid = $object; $html .= $object; } if (!MTrackACL::hasAnyRights($aclid, 'read')) { $denied++; continue; } $html .= "
\n"; if (!count($hits_by_object)) { echo "No matches"; } else { echo "" . count($hits_by_object) . " results in $elapsed\n"; } if ($denied) { echo "
Denied access to $denied items
\n"; } mtrack_foot();