Re: Re-engineering print()
| From: | Josh G | Date: | Thu, 11 Jan 2001 06:37:54 +0000 |
| Subject: | Re: Re-engineering print() | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-33913@lists.php.net to get a copy of this message | ||
Cool, didn't think you could do that. Well never mind me then ;-)
Gfunk
My name was Brian McGee,
I stayed up listening to Queen,
When I was seventeen.
http://www.gfunk007.com/
----- Original Message -----
From: "Matt McClanahan" <cardinal@dodds.net>
To: "Kristofer Widholm" <kristofer_widholm@bigfoot.com>
Cc: <php-general@lists.php.net>
Sent: Thursday, January 11, 2001 5:37 PM
Subject: Re: [PHP] Re-engineering print()
> On Wed, 10 Jan 2001, Kristofer Widholm wrote:
>
> > Basically, I'm wondering if there is a way to redirect print and echo
> > output from PHP to a variable instead of directly to a browser or
> > file stream. What I'm trying to do is create code that can generate
> > an HTML page to a variable that I can manipulate and then later store
> > in a database.
>
> http://www.php.net/manual/ref.outcontrol.php
>
> Specifically, ob_get_contents().
>
> Start an output buffer, include your files, get the contents, and
> ob_ed_clean. Ought to do the trick.
>
> Matt
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>