← All docs
mb_encode_numericentity()
Encodes mapped characters as decimal or hexadecimal numeric entities.
mb_encode_numericentity()
function mb_encode_numericentity(string $string, array $map, ?string $encoding = null, bool $hex = false): string
Encodes mapped characters as decimal or hexadecimal numeric entities.
Parameters:
$string(string)$map(array)$encoding(?string), defaultnull, optional$hex(bool), defaultfalse, optional
Returns: string
Availability
- Compiled (AOT): supported by the Elephc code generator.
eval()(magician interpreter): supported through a declarative interpreter builtin (crates/elephc-magician/src/interpreter/builtins/string/mb_encode_numericentity.rs).
No examples yet. Check examples/ and showcases/ for usage patterns.
Internals
For how mb_encode_numericentity is implemented in the compiler, see the internals page.