I encoded a string using PHP function base64_encode()
. Now decoding it using v using window.atob()
. but it is not decoding "." (dot) properly.
String is IDxwPiBEaXJlY3Rpb24gKDgyLTg0KTo8L3NwYW4+PHNwYW4gc3R5bGU9ImZvbnQtZmFtaWx5OkJvb2ttYW4gT2xkIFN0eWxlIj4gQSBTZW50ZW5jZSBoYXMgYmVlbiBnaXZlbiB3aXRoIGJsYW5rcyB0byB0aGUgZmlsbGVkIHdpdGggYW4gYXBwcm9wcmlhdGUgd29yZC9zLiBGb3VyIGFsdGVybmF0aXZlcyBhcmUgc3VnZ2VzdGVkIGZvciBlYWNoIHF1ZXN0aW9uLiBDaG9vc2UgdGhlIGNvcnJlY3QgYWx0ZXJuYXRpdmUgYW5kIGdpdmUgdGhlIHJpZ2h0IGFuc3dlci4gPC9zcGFuPjwvcD4gPHA+PHNwYW4gc3R5bGU9ImZvbnQtZmFtaWx5OkJvb2ttYW4gT2xkIFN0eWxlIj44NC4gPC9zcGFuPjxzcGFuIHN0eWxlPSJmb250LWZhbWlseTpCb29rbWFuIE9sZCBTdHlsZSI+VGhlIGNyaW1pbmFsIDwvc3Bhbj48c3BhbiBzdHlsZT0iZm9udC1mYW1pbHk6Qm9va21hbiBPbGQgU3R5bGUiPndhcy7igKbigKbigKbigKbigKbigKbigKbigKbigKYuPC9zcGFuPjxzcGFuIHN0eWxlPSJmb250LWZhbWlseTpCb29rbWFuIE9sZCBTdHlsZSI+IGxlc3QgaGUgc2hvdWxkIGVzY2FwZS4gPC9zcGFuPjwvcD4=;
JavaScript giving below output
Direction (82-84): A Sentence has been given with blanks to the filled with an appropriate word/s. Four alternatives are suggested for each question. Choose the correct alternative and give the right answer.
84. The criminal was.â¦â¦â¦â¦â¦â¦â¦â¦â¦. lest he should escape.
But when decoding using php the output is
Direction (82-84): A Sentence has been given with blanks to the filled with an appropriate word/s. Four alternatives are suggested for each question. Choose the correct alternative and give the right answer.
84. The criminal was.......... lest he should escape.