当前位置:网站首页>PHP calculates excel coordinate values, starting with subscript 0

PHP calculates excel coordinate values, starting with subscript 0

2022-06-26 12:25:00 Yotoai Mengtian

function getCdr($cdr = 0)
{
    $temp = '';
    $c = floor($cdr/26);
    if ($c == 0 || $cdr == 25) {
        $temp .= chr($cdr+65);
    } else {
        $y = $cdr%26;
        $temp .= chr($c+64) . chr($y+65);
    }
    return $temp;
}

Only to zz But the demand has been met

原网站

版权声明
本文为[Yotoai Mengtian]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202170520382079.html