且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何在php中每隔一个字符设置一次?

更新时间:2022-12-27 15:20:05

这是一个应该起作用的班轮。

Here's a one liner that should work.

preg_replace('/(\w)(.)?/e', "strtoupper('$1').strtolower('$2')", 'test example');

http://codepad.org/9LC3SzjC