Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^4: problems with decoding by using base64 method

by anil1.perl (Initiate)
on Aug 03, 2016 at 12:55 UTC ( [id://1169082]=note: print w/replies, xml ) Need Help??


in reply to Re^3: problems with decoding by using base64 method
in thread problems with decoding by using base64 method

Hi Derby, Thanks for your reply. We have created a script & doing what you said as below 1.uploading the encoded file to DB 2.Downloading the file & decoding it. Files which have images/scanned images/headers & footers are not opening but the other files (text) are opened. Any thoughts on this? Regards, Anil
  • Comment on Re^4: problems with decoding by using base64 method

Replies are listed 'Best First'.
Re^5: problems with decoding by using base64 method
by CountZero (Bishop) on Aug 03, 2016 at 19:10 UTC
    Did you try to decode an encoded file before it was put in the database? If that works, then your database somehow alters the file between storage and retrieval. If that doesn't work then there is probably something wrong with the encoding.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

    My blog: Imperial Deltronics
      Thanks for your reply, i want to add one more point here. When we try to view that file using a Java script in UI it is opening properly, only problem is when we download that file using a PERL script to our local path it's not opening. Any idea for this issue? Regards, Anil
        What has your investigation of the data itself told you? When you load the data into your Perl script and output it from there, for example to a file, and you open that file both in an editor and you produce a hex dump of that file, does it look correct, like base64 encoded data? When you compare a dump of a file that works with a file that doesn't work, what differences do you see?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1169082]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2024-04-25 18:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found