Hi all, sorry to be not very clear about it. Yes a whole bunch of headers are always sent but from my understanding the excel stream gets confused with the Cake Session cookie. I ran the php script to create the Excel file as a standalone and then in cake. The standalone works well, the one in cake can't be opened in Excel due to a formatting error.
The only difference between the two is in the headers. The cake one has an additional Session cookie set. So i assume that is what is causing the problem. Maybe i can deactivate that for a layout or something.... Cheers Phil On Mar 2, 6:03 pm, Felix Geisendörfer <[EMAIL PROTECTED]> wrote: > > Maybe I'm an idiot, > > Well ... just kidding - I love your stuff ; ). But what I doubt is that > the header that phil copied was sent by CakePHP:> GET > /userAdmin/reports/createExcel HTTP/1.1 > > Host: useradmin.dev.web.mpc.local > > User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.8.1) Gecko/ > > 20061010 Firefox/2.0 > > Accept: text/xml,application/xml,application/xhtml+xml,text/ > > html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5 > > Accept-Language: en-gb,en;q=0.5 > > Accept-Encoding: gzip,deflate > > Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 > > Keep-Alive: 300 > > Connection: keep-alive > > Cookie: CAKEPHP=ntn92a5u894e0lvnn7bgi8k1a4 > > To me this is something that "Mozilla/5.0 (X11; U; Linux i686; en-GB; > rv:1.8.1) Gecko/20061010 Firefox/2.0" would send to a server, but not > CakePHP to a client ; ). You probably copied the GET request instead of > the response one. > > Anyway, what you (phil) probably need is to either overwrite the > 'Content-type' header or to send us some more information about the > excel stream format and if you get any error messages or something. > > -- Felix > --------------------------http://www.thinkingphp.orghttp://www.fg-webdesign.de > > Chris Hartjes wrote: > > On 3/2/07, floepi <[EMAIL PROTECTED]> wrote: > > >> are breaking the export when i use the normal send excel stream > >> option. Does anyone know how i can easily turn the http headers of for > >> a layout?? > > >> Thanks > > >> Phil > > > Maybe I'm an idiot, but won't ANYTHING that is served up by a web > > server have http headers attached to it? Cake uses headers for > > sessions, so that would break Cake for sure, wouldn't it? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
