recherche avec 2 mots (ou plus)
- see also: #370 (first bug report)
- in connection with: #714 (closed)
Steps to reproduce
Faire une recherche avec 2 ou 3 mots :
- prod:
- vagrant dev:
What is the current bug behavior?
- Aucun logiciel pour ...
- Aucun utilisateur pour ...
What is the expected *correct *behavior?
- x logiciels pour ...
- x utilisateurs pour ...
Relevant code
line 137 in the PagesController.php file
// keep spaces , uppercase and transiterate accent characters to non-accent characters.
// Note JGauthier 2019-07-16: just discovered this horror. This is not the correct way to do this.
// TODO This should be fixed
$this->request->query['search'] = strtoupper(Text::slug($searchQuery));
whith this code:
-
logiciel libre
becomesLOGICIEL-LIBRE
-
open studio
becomesOPEN-STUDIO
-
logiciel libre
becomesVISUAL-STUDIO-CODE
Possible fixes
replace
$this->request->query['search'] = strtoupper(Text::slug($searchQuery));
by
$this->request->query['search'] = $searchQuery;
Edited by Fabrice Gangler