Hi all!

I am working on issue #967 <https://github.com/openstreetmap/Nominatim/issues/967>. I have been asked to work on |/lib/Phrase.php 's| ||constructor

But I noticed that Phrase.php constructor does not receive %09-%13 characters. They are somehow removed.

On further inspection, I found that this constructor is called by Geocode.php. The parameter passed itself does not have these characters. I found that

$sPhrase = $this->oDB->getOne(
                    'SELECT make_standard_name(:phrase)',
                    array(':phrase' => $sPhrase),
                    'Cannot normalize query string (is it a UTF-8 string?)'
                );

in Geocode.php alters the $sPhrase and removes those characters. Should I go ahead and look into the the implementation further, or is there any other way?


PS: I initially planned to replace return function of getString function in ParameterParser.php with

return preg_replace('/[\x09|\x10|\x11|\x12|\x13]/', ' ', $this->aParams[$sName]);


Regards,

Rahul

_______________________________________________
Geocoding mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/geocoding

Reply via email to