有些軟體名稱難記,所以才要筆記
有些軟體太難操作,所以才要筆記

2010年9月3日 星期五

PHP 36進位互轉10進位

無意間在PHP.net翻到 string base_convert ( string $number , int $frombase , int $tobase ) 這個函數,可以自訂任意進位來轉換。看來時常出現在網路上的36進位使用非常合適。可以替代之前寫的笨方了。一行函數替代掉十幾行拆字乘法..... //36進位轉10進位 // input z // output 35 echo base_convert($hexadecimal, 36, 10); //10進位轉36進位 // input 36 // output 10 echo base_convert($hexadecimal, 10, 36);
Share:

3 則留言:

  1. Spot On With This Write-up, I Really Suppose This Web Site Wants Rather More Consideration. I?ll Probably Be Again To Learn Much More, Thanks For That Info. uno judi bola

    回覆刪除
  2. Naturally Like Your Website But You Need To Check The Spelling On Quite A Few Of Your Posts. Many Of Them Are Rife With Spelling Problems And I Find It Very Troublesome To Tell The Truth Nevertheless I?ll Certainly Come Back Again.http://www.agenify.com

    回覆刪除
  3. Naturally Like Your Website But You Need To Check The Spelling On Quite A Few Of Your Posts. Many Of Them Are Rife With Spelling Problems And I Find It Very Troublesome To Tell The Truth Nevertheless I?ll Certainly Come Back Again.http://www.agenify.com

    回覆刪除

有熊出沒快點逃

廣告

廣告

BTemplates.com

搜尋此網誌

note.junk.tw. 技術提供:Blogger.

最新文章

Paling Dilihat