jp3cki / mb_str_replace
The mb_str_replace() implementation.
Installs: 11 557
Dependents: 1
Suggesters: 0
Security: 0
Stars: 4
Watchers: 3
Forks: 0
Open Issues: 0
Requires
- php: >=5.1
- ext-mbstring: *
Requires (Dev)
- phpunit/phpunit: 4.* || 5.*
- squizlabs/php_codesniffer: 2.*
This package is auto-updated.
Last update: 2024-12-19 06:33:23 UTC
README
The mb_str_replace() implementation.
Install
- Set up composer.
$ curl -sS https://getcomposer.org/installer | php
$ php composer.phar require jp3cki/mb_str_replace
- You can find the source in
vendor/jp3cki/mb_str_replace/src
.
Other ways:
- Use as submodule (see git manual)
- Copy the source into your development directory (DO NOT rewrite copyright, see License section)
Use
If using composer
You can use mb_str_replace
function after require('vendor/autoload.php')
.
If not using composer
require
or include
the source.
require_once('/path/to/mb_str_replace.function.php');
API
function mb_str_replace( string|array $search, string|array $replace, string|array $subject, string $encoding = 'auto' ) : string|array
Please refer str_replace.
$encoding
= auto
means "use internal-encoding."
Note: This module doesn't support $count
parameter.
License
The MIT License (MIT)
Copyright (C) 2006,2007,2011,2012,2015 by AIZAWA Hina <hina@bouhime.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.