标签: php string substring echo
$big = "new york city"; $small ="or"; $pos = strpos($big, $small); echo $pos;
返回5但我希望它返回6,这是“r”的位置。提前致谢
答案 0 :(得分:-1)
$big = "new york city"; $small ="or"; $pos = strpos($big, $small); $pos = $pos + strlen($small) - 1; echo $pos;