如何在php上使用base64_encode字节数组?
在java上
new BASE64Encoder().encode(byte[] bytes);
Run Code Online (Sandbox Code Playgroud)
Isr*_*iro -3
使用base64_encode($stringToEncode) 和base64_decode($stringToDecode)
例子:
$string = 'Test String';
$coded = base64_encode($string);
echo $coded;
// TyByYXRvIHJldSBhIHJvcGEgZG8gcmVpIGRlIFJvbWE=
$original = base64_decode($coded);
echo $original;
// Test String
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1323 次 |
| 最近记录: |