|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
header() problem
I am having problems with the Mitchell Harper tuitorial on Blobbing. Everything works fine until I click on download file. I get the following error message when I try to download a MS Word doc.
Warning: Cannot add header information - headers already sent by (output started at C:\Xitami\webpages\donna\downloadfile.php:7) in C:\Xitami\webpages\donna\downloadfile.php on line 29 {\rtf1\ansi\ansicpg1252\uc1 \deff0\deflang1033\deflangfe1033{\fonttbl{\f0\from an\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f182....... After lines and lines of this, the doc content does show up at the bottom. I'm wondering if the problem is that I'm running Xitami instead of Apache/IIS? If so, does anyone know how to make this code work with Xitami? I have PHP v4.1.1 and have tried all the previous suggestions such as removing any spaces before the opening <?php in my download.php script and removing the @'s from the scripts. Any help will be greatly appreciated! |
|
#2
|
|||
|
|||
|
Are you sure you're not echo'ing anything before you try to send the headers?
And if you absolutely have to echo something before the headers gets sent, you could play around with output buffering.. Example: it exectues all the code, but the output is buffered (and output), and it outputs when you tell it to.. http://www.php.net/manual/en/ref.outcontrol.php
__________________
Best Regards, Håvard Lindset |
|
#3
|
|||
|
|||
|
Thanks for your help! It's working now.
|
![]() |
| Viewing: Dev Articles Community Forums > Databases > General SQL Development > header() problem |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|