BASE64_DECODE(3) 1 BASE64_DECODE(3)
base64_decode - Decodes data encoded with MIME base64
SYNOPSIS
string base64_decode (string $data, [bool $strict = false])
DESCRIPTION
Decodes a base64 encoded $data.
PARAMETERS
o $data
- The encoded data.
o $strict
- Returns FALSE if input contains character from outside the base64 alphabet.
RETURN VALUES
Returns the original data or FALSE on failure. The returned data may be binary.
CHANGELOG
+--------+---------------+
|Version | |
| | |
| | Description |
| | |
+--------+---------------+
| 5.2.0 | |
| | |
| | $strict added |
| | |
+--------+---------------+
EXAMPLES
Example #1
base64_decode(3) example
<?php
$str = 'VGhpcyBpcyBhbiBlbmNvZGVkIHN0cmluZw==';
echo base64_decode($str);
?>
The above example will output:
This is an encoded string
SEE ALSO
base64_encode(3), RFC 2045 section 6.8.
PHP Documentation Group BASE64_DECODE(3)