How to check if a string is base64 encoded string?
-
How can I check if a string is base64 encoded string? :omg:
-
How can I check if a string is base64 encoded string? :omg:
-
How can I check if a string is base64 encoded string? :omg:
1. Check if the length is an exact multiple of 4. 2. Try to decode it and catch any error.
Best wishes, Hans
-
Manually check whether the string contains only the characters (A-Z, a-z, , 0-9, + and /) that can be the output of Base64 encoding. Such a string can be successfully decoded. :cool:
thanks
-
1. Check if the length is an exact multiple of 4. 2. Try to decode it and catch any error.
Best wishes, Hans
thanks
-
1. Check if the length is an exact multiple of 4. 2. Try to decode it and catch any error.
Best wishes, Hans
Can't understand why someone downvoted this.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
[My articles]