projects
/
core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
9598034
)
Added isBase64Encoded() with a simple check on Base64-encoded messages.
author
Roland Häder
<roland@mxchange.org>
Mon, 18 Apr 2011 16:53:56 +0000
(16:53 +0000)
committer
Roland Häder
<roland@mxchange.org>
Mon, 18 Apr 2011 16:53:56 +0000
(16:53 +0000)
inc/classes/main/class_BaseFrameworkSystem.php
patch
|
blob
|
history
diff --git
a/inc/classes/main/class_BaseFrameworkSystem.php
b/inc/classes/main/class_BaseFrameworkSystem.php
index 00ccf224f3d235af80341c48a5bf2f66552656da..7a43629c0abf8dc23034e7b64f7bee5dab8d63d4 100644
(file)
--- a/
inc/classes/main/class_BaseFrameworkSystem.php
+++ b/
inc/classes/main/class_BaseFrameworkSystem.php
@@
-1807,6
+1807,20
@@
class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
// Return it
return $strFinal;
}
+
+ /**
+ * Checks wether the given encoded data was encoded with Base64
+ *
+ * @param $encodedData Encoded data we shall check
+ * @return $isBase64 Wether the encoded data is Base64
+ */
+ protected function isBase64Encoded ($encodedData) {
+ // Determine it
+ $isBase64 = (@base64_decode($encodedData, true) !== false);
+
+ // Return it
+ return $isBase64;
+ }
}
// [EOF]