求解,正则表达式高手~
eg,我的链接原本是$url=http://www.baidu.com.cn/edms/ed33
我现在想用php的正则表达式匹配后,把前缀去掉,变成
$url=baidu.com.cn/edms/ed33
正则表达式应该怎么写?
------解决方案--------------------echo preg_replace('#https?://www\.#','',$url);
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn