Regular text searches for words with the first two letters in capital letters and the third and subsequent letters in lower case. And the second letter omits the register. It was: So It became: So

My regular is scary as hell:

$in=preg_replace('/\b([A-Z衼袡笑校袣袝袧袚楔些袟啸歇肖蝎袙袗袩袪袨袥袛袞协携效小袦袠孝鞋袘挟])([A-Z衼袡笑校袣袝袧袚楔些袟啸歇肖蝎袙袗袩袪袨袥袛袞协携效小袦袠孝鞋袘挟])([a-z褢泄褑褍泻械薪谐褕褖蟹褏褗褎褘胁邪锌褉芯谢写卸褝褟褔褋屑懈褌褜斜褞].*)\b/e','"$1".strtolower("$2")."$3"',$in,10); 

In addition, some not quite working, it works after one time, it is not clear why. Who will help to make regular chocolate candy? Oneline.

Everything happens in the encoding 1251

    1 answer 1

    shorter ([A-Z袗-携]) ([A-Z袗-携]). +? \ s