php remove specified characters in a given string using "preg_replace()"
How to re开发者_JAVA技巧move the specific characters in a string(strip the "http://www." from a string)
For example, my string is like this: http://www.hooeeywebprint.com
You can try this one
var_dump(preg_replace("/^[^\.]*\.(.*)/", "\\1", "http://www.example.com"));
which removes everything from string up to first .
character, including it.
精彩评论