开发者

Strip letters in php

We have variable with text:

$text = 'I use something similar to pull the most recent pos开发者_如何转开发t from my blog and display a snapshot of it on my home page.';

How to strip first 40 symbols of this text? (including spaces).

Should work like this:

echo strip_text($text, 40);

Thanks.


With substr:

echo substr($text, 40);


Use PHP's substr:

$stripped = substr($text, 0, 40);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜