<?php $a = "123@abc#456"; $b = (strpos($a,"@")); $c = (strpos($a,"#")); echo substr($a,$b+1,$c-1); ?>
$str = $_SERVER[REQUEST_URI]; $arr = explode("/",$str); $last = $arr[count($arr)-2];
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号