Answers for "php encode base64"

PHP
1

php detect base64 encoding

function is_base64_encoded($data)
{
    if (preg_match('%^[a-zA-Z0-9/+]*={0,2}$%', $data)) {
       return TRUE;
    } else {
       return FALSE;
    }
};

is_base64_encoded("iash21iawhdj98UH3"); // true
is_base64_encoded("#iu3498r"); // false
is_base64_encoded("asiudfh9w=8uihf"); // false
is_base64_encoded("a398UIhnj43f/1!+sadfh3w84hduihhjw=="); // false
Posted by: Guest on November-17-2019
3

how do decode base64 php

base64_decode('base64-string-goes-here');
Posted by: Guest on June-05-2020
0

base64 decode php

GFG, A computer Science Portal For Geeks
1
Posted by: Guest on March-04-2021

Browse Popular Code Answers by Language