Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:15538 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 84801 invoked by uid 1010); 22 Mar 2005 13:45:58 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 84768 invoked from network); 22 Mar 2005 13:45:58 -0000 Received: from unknown (HELO yahoo.co.kr) (127.0.0.1) by localhost with SMTP; 22 Mar 2005 13:45:58 -0000 X-Host-Fingerprint: 66.111.4.25 out1.smtp.messagingengine.com Received: from ([66.111.4.25:52330] helo=out1.smtp.messagingengine.com) by pb1.pair.com (ecelerity HEAD r(5268)) with SMTP id D1/3D-36163-59120424 for ; Tue, 22 Mar 2005 08:45:58 -0500 Received: from web2.messagingengine.com (web2.internal [10.202.2.211]) by frontend1.messagingengine.com (Postfix) with ESMTP id 0AAC6C63276; Tue, 22 Mar 2005 08:45:55 -0500 (EST) Received: by web2.messagingengine.com (Postfix, from userid 99) id D1B39317D; Tue, 22 Mar 2005 08:45:50 -0500 (EST) Message-ID: <1111499150.32517.230143893@webmail.messagingengine.com> X-Sasl-Enc: VvOoegDA3zG2PMCMS1NIWcvTbHXT1RAYeHFLyO8r8HFG 1111499150 To: "Arjun Jain" , "php-dev" Content-Disposition: inline Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="iso-8859-1" MIME-Version: 1.0 X-Mailer: MIME::Lite 1.5 (F2.73; T1.001; A1.64; B3.05; Q3.03) References: <42401CE6.4030301@picorp.com> In-Reply-To: <42401CE6.4030301@picorp.com> Date: Tue, 22 Mar 2005 05:45:50 -0800 Subject: Re: [PHP-DEV] php streams - generating the http header From: kameshj@fastmail.fm ("Kamesh Jayachandran") Hi, Have a look at main/SAPI.c for the function sapi_header_op PHP_FUNCTION(header)in ext/standard/head.c With reagrds Kamesh Jayachandran On Tue, 22 Mar 2005 18:55:58 +0530, "Arjun Jain" said: > Hi everyone, > > Back Again :). I tried searching around, but all in vain. > > My question is that how do i use the php stream to generate > my custom header and then write to it the corresponding file? > I could get that php_stream *stream need to be created and then > php_stream_write needs to be used to write to it. But how > do I open the stream? > > Basically I want to write a file to the browser, say a .png file > from my extension. I can not use the header() function of php. > And even if i use it, how do i send the png file to the browser. > I would prefer not using the header() funcion and write my own > header. > > Any pointers please? Thanking you in advance. > > Regards, > aj > http://arjun.notlong.com > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php >