# symfony/polyfill-mbstring

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/symfony-polyfill-mbstring).**

7,831 stars · 38 forks · PHP · MIT

## Links

- GitHub: https://github.com/symfony/polyfill-mbstring
- Homepage: https://symfony.com/polyfill-mbstring
- awesome-repositories: https://awesome-repositories.com/repository/symfony-polyfill-mbstring.md

## Topics

`compatibility` `component` `javascript` `mbstring` `polyfill` `portable` `shim` `symfony` `symfony-component` `symfony-polyfill`

## Description

This project is a PHP compatibility layer that implements multi-byte string functions for environments where the native Mbstring extension is not installed. It serves as a library for processing text in various character encodings to ensure consistent string handling across different servers.

The library provides a set of tools for internationalization text handling, allowing for the processing of non-English characters and diverse languages. It ensures correct string length and manipulation for text containing characters beyond the basic ASCII set.

## Tags

### Programming Languages & Runtimes

- [PHP Polyfills](https://awesome-repositories.com/f/programming-languages-runtimes/php-polyfills.md) — Replicates native C-based extension functions using pure PHP to ensure consistent behavior across environments.
- [Native Function Mocking](https://awesome-repositories.com/f/programming-languages-runtimes/function-signatures/native-function-mocking.md) — Provides global functions that mirror the exact signature and behavior of missing native extensions.
- [Unicode and Byte String Distinction](https://awesome-repositories.com/f/programming-languages-runtimes/unicode-and-byte-string-distinction.md) — Handles the distinction and manipulation of multi-byte strings versus raw byte sequences.
- [Multi-byte Offset Calculations](https://awesome-repositories.com/f/programming-languages-runtimes/unicode-and-byte-string-distinction/string-byte-size-calculators/multi-byte-offset-calculations.md) — Provides logic to process strings by calculating byte offsets based on specific character encoding sets.
- [Unicode Text Handling](https://awesome-repositories.com/f/programming-languages-runtimes/unicode-text-handling.md) — Provides runtime support for processing multi-byte encoded strings and calculating character offsets for diverse languages.
- [Runtime Compatibility Layers](https://awesome-repositories.com/f/programming-languages-runtimes/runtime-compatibility-layers.md) — Provides missing system extensions to ensure code runs consistently regardless of installed server modules.

### Development Tools & Productivity

- [Mbstring Polyfills](https://awesome-repositories.com/f/development-tools-productivity/php-5-x-compatibility-polyfills/mbstring-polyfills.md) — Implements multi-byte string functions for environments where the native Mbstring extension is not installed.
- [String Processing Libraries](https://awesome-repositories.com/f/development-tools-productivity/string-processing-libraries.md) — Provides a comprehensive set of utilities for manipulating text strings with support for various character encodings.

### Software Engineering & Architecture

- [String Processing Algorithms](https://awesome-repositories.com/f/software-engineering-architecture/string-processing-algorithms.md) — Implements complex string manipulation and processing algorithms for multi-byte text. ([source](https://cdn.jsdelivr.net/gh/symfony/polyfill-mbstring@1.x/README.md))
- [Polyfill Function Guards](https://awesome-repositories.com/f/software-engineering-architecture/dynamic-task-scheduling/runtime-invokers/conditional-function-dispatch/polyfill-function-guards.md) — Implements guards to ensure polyfill functions are only defined if the native extension is missing.
