Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[10.x] introduce Str::substrPos #48421

Merged
merged 5 commits into from
Sep 18, 2023

Conversation

amacado
Copy link
Contributor

@amacado amacado commented Sep 15, 2023

This pull request introduces a multi-byte safe method to determine the position of the first occurrence of substring in a string. It's basically a wrapper for mb_strpos().

I've implemented the helper method as static call and in fluent style. The naming follow's other substr* methods like Str::substrCount() or Str::substrReplace().

@amacado amacado changed the title [10.x] introduce Str::substrPos [10.x] introduce Str::substrPos Sep 18, 2023
@taylorotwell taylorotwell merged commit f0ef58d into laravel:10.x Sep 18, 2023
20 checks passed
@amacado amacado deleted the feature/str-substrpos branch September 18, 2023 15:12
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.

None yet

2 participants