- Run
composer req sunzinet/sz-quickfinder
- Activate sz-quickfinder in the Extens**ionmanager
- Include TypoScript
- Include sz-quickfinder in your template. Example:
lib.contents {
pageSearch =< lib.tx_szquickfinder
}
| Type | Default | |
|---|---|---|
| homePageUid | integer | 2 |
| searchPid | integer | 140 |
| newsPid | integer | 28 |
| regEx | string | %|% |
| maxResults | integer | 3 |
| includeNavHiddenPages | bool | false |
| orderBy | string | uid |
| ascending | bool | true |
| customSearch | ||
| class | string | |
| searchFields | searchFields | |
| blacklistPid | string |
All settings can be overridden in 'customSearch' section.
It's required to give a data-attribute to the body-tag called "data-languid" with the current sys_language_uid to make multilingualism work.
page {
bodyTagCObject = COA
bodyTagCObject {
10 = TEXT
10.value = default
10.stdWrap.noTrimWrap = |language-| |
stdWrap.trim = 1
stdWrap.dataWrap = <body class="|" data-languid="{sitelanguage:languageId}">
}
}
- Autocomplete doesn't work correctly on detail pages (e.g. tx_news).
Workaround: Set
$GLOBALS['TYPO3_CONF_VARS']['FE']['pageNotFoundOnCHashError'] = false - Search won't be executed on any page if
pageNotFoundOnCHashErroractivated. Use$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters']
composer install
./vendor/bin/phpunit -c Tests/phpunit.xml- Redesign interfaces
for example:
- interface SearchResult
- interface PageResult implements SearchResult
- interface FileResult implements SearchResult
- interface NewsResult implements SearchResult