Overview
KB
Technical FAQ
PHP Manual
CSS2 Manual
HTML Manual
JS Guide
JS Reference
PhpDock Manual
Nu-Coder Manual
PhpExpress Manual
PHP Joomla
Development
Learn PHP
 
<chunk_splitconvert_uudecode>
^String FunctionsLast updated: Mon, 26 Oct 2026

convert_cyr_string

(PHP 4, PHP 5, PHP 7)

convert_cyr_string — Convert from one Cyrillic character set to another

Warning

This function has been DEPRECATED as of PHP 7.4.0, and REMOVED as of PHP 8.0.0. Relying on this function is highly discouraged.

Description

function convert_cyr_string(string $str, string $from, string $to): string

Converts from one Cyrillic character set to another.

Parameters

str

The string to be converted.

from

The source Cyrillic character set, as a single character.

to

The target Cyrillic character set, as a single character.

Supported characters are:

  • k - koi8-r

  • w - windows-1251

  • i - iso8859-5

  • a - x-cp866

  • d - x-cp866

  • m - x-mac-cyrillic

Return Values

Returns the converted string.

Changelog

Version Description
8.0.0 Removed this function.
7.4.0 Deprecated this function.

Notes

Note:

This function is binary-safe.

See Also

  • mb_convert_encoding() - Convert a string from one character encoding to another
  • iconv() - Convert a string from one character encoding to another


<chunk_splitconvert_uudecode>
^String FunctionsLast updated: Mon, 26 Oct 2026