Canot download the uploaded image

By Al-ayam

I have developed one user registration plugin .  (This is an old site developed using elgg1.7.8) In his plugin I have file uploading also.

For that i used the same code like in the file uploading of Elgg's core FILE plugin.

Also I have one page for displaying the unvalidated users. Here I want add the links along with the name of the attachments (also have to download these files when we click on them).

Here also i used the same code in the download.php of FILE plugin. I could list the file names there , but when i click on the file name I got the error like below:

"The image "Path" cannot be displayed because it contains errors."

The images uploaded inthe data directory successfully and I can see this there.

Hope anyone  suggest a solution for this??

Please help..