function code62($x){
    $show='';
    while($x>0){
        $s=$x % 62;
        if ($s>35){
            $s=chr($s+61);
        }elseif($s>9&&$s<=35){
            $s=chr($s+55);
        }
        $show.=$s;
        $x=floor($x/62);
    }
    return $show;
}
function shorturl($url){
    $url=crc32($url);
    $result=sprintf("%u",$url);
    return code62($result);
}

相关文章:

  • 2021-11-27
  • 2022-12-23
  • 2022-12-23
  • 2021-12-12
  • 2021-07-27
  • 2021-12-28
  • 2021-12-28
  • 2021-10-20
猜你喜欢
  • 2021-05-21
  • 2021-12-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-20
  • 2022-12-23
相关资源
相似解决方案