Skip to content

Conversation

@utilmind
Copy link

The UTF8_SPACES constant allows me to easily add more characters to trim from the string.

E.g.
echo mb_trim(' —888-888-00-00-', UTF8_SPACES.'-–—');
will trim both spaces and dashes from the phone numbers.

define UTF8_SPACES to be able to add more characters
@utilmind
Copy link
Author

This PR not related to issue I posted separately (at https://github.com/PHP-Polyfills/mb_trim/issues).
This is different, but consider fixing that issue too, either by specifying the type of return value or removing the type hints.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant