[pmwiki-users] Search with non-ascii characters in url q= parameter

Petko Yotov 5ko at 5ko.fr
Tue Jan 24 03:55:56 PST 2023


You didn't mention this, but I assume that you deleted the file 
wiki.d/.pageindex as explained in PmWiki:UTF-8, and that there are pages 
containing the search terms.

Do the search results show correctly "Results of search for _ bär_: 0 
pages found of X pages searched"?

Do searches for other terms work? If not, check the pagelist template.

If you write (:pagelist bär:) in a page, does it find the other page 
containing "bär" (including this page, as it also contains "bär")?

Do you have any recipes that deal with international page names? Like 
ISO8859MakePageNamePatterns? Or recipes that modify the $_REQUEST array?

You can create a new wiki field on your server, and include only 
xlpage-utf-8.php, then add a page with the international characters, 
then search for these characters. If the search finds the page, then 
there is something in your other installation that prevents it.

In such a case, I'd follow the steps described at PmWiki:Troubleshooting 
to try and find what could cause the problem.

If a pristine PmWiki installation search doesn't find the international 
characters, I'd look into the server documentation to see if something 
needs to be enabled/configured on the server.

Petko
On 24/01/2023 12:22, Hans wrote:

> Hello Petko,
> 
> Tuesday, January 24, 2023, 10:37:15 AM, you wrote:
> 
>> Yes, PmWiki can handle international characters in searches (try on 
>> pmwiki.org), but you may need to enable UTF-8.
> 
>> See https://www.pmwiki.org/wiki/PmWiki/UTF-8 as this may not be 
>> trivial for existing wikis.
> 
> so I added to my test wiki config.php, near the top:
> 
> include_once("$FarmD/scripts/xlpage-utf-8.php");
> $DefaultPageCharset = array(''=>'ISO-8859-1');
> 
> wiki.d wiki file pages contain:
> charset=ISO-8859-1
> 
> Html source in the <head> contains an entry for utf-8:
> <meta http-equiv='Content-Type' content='text/html; charset=utf-8' />
> 
> Now the search does not yield any results if the query string contains 
> an  "ä" for instance.
> But the  "ä" is displayed correctly in th eurl and in the search box.
> 
> So what may be stopping the search yielding results?
> 
> Best regards,
> Hans
> mailto:design at bracker.uk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20230124/1e153629/attachment.html>


More information about the pmwiki-users mailing list