FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Re: uniwersalny writer
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
Re: uniwersalny writer [message #171978] Mon, 24 January 2011 20:43 Go to next message
Peter H. Coffin is currently offline  Peter H. Coffin
Messages: 245
Registered: September 2010
Karma: 0
Senior Member
On Mon, 24 Jan 2011 14:35:17 +0100, smerf wrote:
> chce napisac uniwersalnego writera piszacego na ekran albo do pliku.
> sadze ze takie cos powinno wydrukowac na ekranie
>
> <?php
> ini_set('display_errors', '1');
> error_reporting(E_ALL);
>
> $file = fopen('php://stdout', 'w');
> fwrite($file, "test \n");
> fclose($file);
> ?>
>

> No niestety, ekran jest pusty. Za to w konsoli drukuje ladnie 'test'.
> Czy nie da sie w ten sposob wywolac skryptu webowego, czy tylko
> zostaje echo lub print ?

php://stdout does not send http headers, if the blank thing is a web
page.

--
76. If the hero runs up to my roof, I will not run up after him and
struggle with him in an attempt to push him over the edge. I will
also not engage him at the edge of a cliff. (In the middle of a
rope-bridge over a river of lava is not even worth considering.)
Re: uniwersalny writer [message #171982 is a reply to message #171978] Tue, 25 January 2011 09:49 Go to previous messageGo to next message
smerf is currently offline  smerf
Messages: 12
Registered: January 2011
Karma: 0
Junior Member
On 2011-01-24 21:43, Peter H. Coffin wrote:
> On Mon, 24 Jan 2011 14:35:17 +0100, smerf wrote:
>> chce napisac uniwersalnego writera piszacego na ekran albo do pliku.
>> sadze ze takie cos powinno wydrukowac na ekranie
>>
>> <?php
>> ini_set('display_errors', '1');
>> error_reporting(E_ALL);
>>
>> $file = fopen('php://stdout', 'w');
>> fwrite($file, "test \n");
>> fclose($file);
>> ?>
>>
>
>> No niestety, ekran jest pusty. Za to w konsoli drukuje ladnie 'test'.
>> Czy nie da sie w ten sposob wywolac skryptu webowego, czy tylko
>> zostaje echo lub print ?
>
> php://stdout does not send http headers, if the blank thing is a web
> page.
>

Thanks for your answer instead of I wrote in polish :)
Re: uniwersalny writer [message #171984 is a reply to message #171982] Tue, 25 January 2011 15:43 Go to previous message
Peter H. Coffin is currently offline  Peter H. Coffin
Messages: 245
Registered: September 2010
Karma: 0
Senior Member
On Tue, 25 Jan 2011 10:49:53 +0100, smerf wrote:
> On 2011-01-24 21:43, Peter H. Coffin wrote:
>> On Mon, 24 Jan 2011 14:35:17 +0100, smerf wrote:
>>> No niestety, ekran jest pusty. Za to w konsoli drukuje ladnie 'test'.
>>> Czy nie da sie w ten sposob wywolac skryptu webowego, czy tylko
>>> zostaje echo lub print ?
>>
>> php://stdout does not send http headers, if the blank thing is a web
>> page.
>>
>
> Thanks for your answer instead of I wrote in polish :)

Google's translation tools work well enough to get the meaning of the
question, but aren't good enough to compose an answer.

--
Cunningham's Second Law:
It's always more complex than you expect, even when you take
Cunningham's Second Law into account.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: is_a vs. instanceof()?
Next Topic: Implement Php performace
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sat Nov 23 15:08:50 GMT 2024

Total time taken to generate the page: 0.02631 seconds