How does php replace part of a string – PHP problem

How to replace part of the string in php: first create a PHP sample file; then use the “str_replace” function to replace the specified string. Recommendation: “PHP Video Tutorial” PHP replaces the specified string Use str_replace to replace the specified character String $param = & # 39; Banana peel is what rubbish & # 39;; $pattOne = [ & # 39; What rubbish & # 39;, & # 39; What rubbish & # 39;, & # 39; what kind of garbage & # 39;, & # 39; What kind of rubbish & # 39;, & # 39; what kind of garbage & # 39;, & # 39; what kind of garbage & # 39;, ]; $new_param = str_replace($pattone, '*', $param); $param = ' banana peel is What kind of rubbish’; $patttwo = [ //Put the words with more words in front to match first & # 39; Is it & # 39;, & # 39; Garbage & # 39;, & # 39; Does not belong to & # 39;, & # 39; Does it count & # 39;, ‘Which kind’, ‘Which category’, ‘Which’, & # 39; Which type & # 39;, & # 39; belongs to & # 39;, ‘A’,…

Contact Us

Contact us

181-3619-1160

Online consultation: QQ交谈

E-mail: [email protected]

Working hours: Monday to Friday, 9:00-17:30, holidays off

Follow wechat
Scan wechat and follow us

Scan wechat and follow us

Follow Weibo
Back to top
首页
微信
电话
搜索