Added encodeURIComponent() on the file path url

base64_encode() produces "+" that php will treat as whitespace when decoded into $_GET, then base64_decode() fails. Usually affects file names which contain multibyte characters.