Re: [PHP] File download problem

2008-08-19 Thread Stefano Noffke
of each file I download with my script? Thanks Stefano Stefano Noffke wrote: Hi, Thank you for your reply. I tried your code, but the problem remains. I still can download PDF, TXT, and MP3 fine, but the ODT, DOC, and JPG are still corrupted. I wonder why it works with some files

Re: [PHP] File download problem

2008-08-19 Thread Stefano Noffke
Subject: Re: [PHP] File download problem From: Stefano Noffke [EMAIL PROTECTED] Date: Tue, 19 Aug 2008 15:17:25 +0200 To: php-general@lists.php.net To: php-general@lists.php.net I checked the files with an HEX editor, and I found that each downloaded file starts with EFBBBF, and after those three

Re: [PHP] File download problem

2008-08-19 Thread Stefano Noffke
I just add this comment for reference. I found this bug report on the PHP Web site: http://bugs.php.net/bug.php?id=22108 That bug explains everything :) Stefano Stefano Noffke wrote: Thanks for the reply. I think I found the problem here: The php file was saved with UTF-8 encoding

[PHP] File download problem

2008-08-18 Thread Stefano Noffke
Greetings, I need to create a script to let registered users to download files from a non-public folder. The files name, type, and size are stored in a MySQL Database. The user need to click on a link, and a PHP script should handle the download of the file. Here is how I organized it:

Re: [PHP] File download problem

2008-08-18 Thread Stefano Noffke
(); The rb in the fopen function instructs PHP to open the file for reading in a binary safe manner. Hope this helps. Ash www.ashleysheridan.co.uk Oggetto: [PHP] File download problem Da: Stefano Noffke [EMAIL PROTECTED] Data: Mon

[PHP] iconv() problem

2008-06-26 Thread Stefano Noffke
Greetings, I have a problem with iconv(), and I need help solving it. Here is the background: I have a Web page with a Form that saves data to a MySQL database. I need to retrieve the data from the database and create a PDF document with FPDF. The Web Page, the database, and the browser

[PHP] Re: iconv() problem

2008-06-26 Thread Stefano Noffke
Nevermind... I made a mistake. I was actually parsing the string two times; therefore, the source string was not encoded as ISO-8859 anymore the second time. It is working fine now... Stefano Stefano Noffke ha scritto: Greetings, I have a problem with iconv(), and I need help solving