Project

General

Profile

Bug #16693 ยป bug_4470.diff

Administrator Admin, 2007-02-06 10:59

View differences:

typo3/sysext/indexed_search/ext_typoscript_setup.txt (Arbeitskopie)
search {
rootPidList =
page_links = 10
exact_count = 0
detect_sys_domain_records = 0
defaultFreeIndexUidList =
}
typo3/sysext/indexed_search/pi/class.tx_indexedsearch.php (Arbeitskopie)
$c = 0; // Result pointer: Counts up the position in the current search-result
$grouping_phashes = array(); // Used to filter out duplicates.
$grouping_chashes = array(); // Used to filter out duplicates BASED ON cHash.
$firstRow = Array(); // Will hold the first row in result - used to calculate relative hit-ratings.
$resultRows = Array(); // Will hold the results rows for display.
$firstRow = array(); // Will hold the first row in result - used to calculate relative hit-ratings.
$resultRows = array(); // Will hold the results rows for display.
$exactCount = $this->conf['search.']['exact_count']; // Continue counting and checking of results even if we are sure they are not displayed in this request. This will slow down your page rendering, but it allows precise search result counters.
// Now, traverse result and put the rows to be displayed into an array
// Each row should contain the fields from 'ISEC.*, IP.*' combined + artificial fields "show_resume" (boolean) and "result_number" (counter)
while($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) {
......
if ($c > $pointer * $this->piVars['results']) {
$row['result_number'] = $c;
$resultRows[] = $row;
// This may lead to a problem: If the result check is not stopped here, the search will take longer. However the result counter will not filter out grouped cHashes/pHashes that were not processed yet.
if (($c+1) > ($pointer+1)*$this->piVars['results']) break;
// This may lead to a problem: If the result check is not stopped here, the search will take longer. However the result counter will not filter out grouped cHashes/pHashes that were not processed yet. You can change this behavior using the "exact_count" property (see above).
if (!$exactCount && (($c+1) > ($pointer+1)*$this->piVars['results'])) { break; }
}
} else {
$count--; // Skip this row if the user cannot view it (missing permission)
    (1-1/1)