Actions
Bug #15444
closedexternal documents not always indexed
Start date:
2006-01-18
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
External documents are not indexed, if they are integrated via Filelist. They erroneously get a double slash, so the test in t3lib_div::getFileAbsFileName(...) fails, thus the file is not indexed.
I think this is related to a flaw in the construction of the path to the documents inserted via the Filellist, which constructs relative references to documents as absolute paths somewhere...
By replacing the double slashes with one singe slash i got the indexing to work. All I did was replacing the lines (about lines 758ff):
} elseif (!$qParts['query']) {
$localFile = t3lib_div::getFileAbsFileName(PATH_site.$linkSource);
if ($localFile && @is_file($localFile)) {
// Index local file:
$this->indexRegularDocument($linkSource);
}
}
with these (changed ones marked with // lg):
} elseif (!$qParts['query']) {
$localFile = ereg_replace('//','/',PATH_site.$linkSource); // lg
$localFile = t3lib_div::getFileAbsFileName($localFile); // lg
if ($localFile && @is_file($localFile)) {
// Index local file:
$this->indexRegularDocument($localFile); // lg
}
}
Hope this helps.
(issue imported from #M2306)
Actions