$salary_levels = Db::select("select * from hr_salary_level where SalaryID='ZA105'");
$salary_level = [];
foreach ($salary_levels as $key=>$it){
$Express = $it['Express'];
if(strpos($Express,"(1,") !== false){
// echo "{$it['ID']}包含\n";
$salary_level[0] = $it;
}
if(strpos($Express,",1,") !== false){
// echo "{$it['ID']}包含\n";
$salary_level[0] = $it;
}
if(strpos($Express,",1)") !== false){
// echo "{$it['ID']}包含\n";
$salary_level[0] = $it;
}
if(strpos($Express,"(1)") !== false){
// echo "{$it['ID']}包含\n";
$salary_level[0] = $it;
}
}
php字符串包含某字符串,使用strpos
最新推荐文章于 2024-04-13 05:00:00 发布