18 public static function encode($bytes) {
20 $bytes =
rtrim($bytes,
'=');
21 return strtr($bytes,
'+/',
'-_');
30 public static function decode($bytes) {
31 $bytes = strtr($bytes,
'-_',
'+/');
32 return base64_decode($bytes);
Encode and decode Base 64 URL.
static decode($bytes)
Decode base 64 URL.
static encode($bytes)
Encode base 64 URL.