PHP - Return everything after delimiter

后端 未结 7 1618
北恋
北恋 2021-01-19 01:00

There are similar questions in SO, but I couldn\'t find any exactly like this. I need to remove everything up to (and including) a particular delimiter. For example, given t

7条回答
  •  清酒与你
    2021-01-19 01:32

        $str = "File:MyFile.jpg";
    
        $position = strpos($str, ':');//get position of ':'
    
        $filename= substr($str, $position+1);//get substring after this position
    

提交回复
热议问题