Here is an example from the PHP interactive shell:
php > $str = "e.g. Ā to ā, Ê to ê, Į to į, etc";
php > print_r(mb_strtolower($str));
e.g. ā to ā, ê to ê, į to į, etc
php > print_r(mb_strtoupper($str));
E.G. Ā TO Ā, Ê TO Ê, Į TO Į, ETC
Petko
--
If you upgrade : https://www.pmwiki.org/Upgrades
On 18/10/2022 06:46, Simon wrote:
> Can anyone suggest a means of converting diacritic [1]characters to
> lower case,
> e.g. Ā to ā, Ê to ê, Į to į, etc
> other than creating a translation table?
>
> thanks
>
> Simon
>
>
>
> Links:
> ------
> [1] https://en.wikipedia.org/wiki/Diacritic
> _______________________________________________
> pmwiki-devel mailing list
> pmwiki...@pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-devel
_______________________________________________
pmwiki-devel mailing list
pmwiki...@pmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-devel
$entity = mb_convert_encoding($decoded, 'HTML');
You may or may not need to specify a $from_encoding argument. From the
documentation it seems before PHP 8.0 $from_encoding was required.
Documentation:
https://php.net/mb_convert_encoding
Petko
--
If you upgrade : https://www.pmwiki.org/Upgrades