|
-
Jul 5th, 2005, 09:24 PM
#1
Thread Starter
Frenzied Member
[ASP]Response.clear >> what is its equivalen in PHP
Response.clear
does anyone know its equivalent in php ?
-
Jul 6th, 2005, 02:16 AM
#2
Re: [ASP]Response.clear >> what is its equivalen in PHP
What does response.clear do?
-
Jul 6th, 2005, 02:24 AM
#3
Re: [ASP]Response.clear >> what is its equivalen in PHP
It clears the buffered HTML output after the previous flush.
-
Jul 6th, 2005, 04:55 AM
#4
Re: [ASP]Response.clear >> what is its equivalen in PHP
Yes there is an equivilent in PHP. However, you have to turn on output buffering. You can find information about it here.
Basically, you should use the ob_start() function to start the buffer and call ob_flush() whenever you want to flush the buffer. By default however, PHP handles all output control.
-
Jul 6th, 2005, 05:04 AM
#5
Re: [ASP]Response.clear >> what is its equivalen in PHP
Same thing in ASP, you need to enable it first. Of course I didn't know its PHP equivalent nor do I think I'll ever use it.
-
Jul 6th, 2005, 08:27 AM
#6
Re: [ASP]Response.clear >> what is its equivalen in PHP
I use output buffering only when I have something (an include file or a function) that writes to the console, but I really want it in a variable.
Code:
ob_start();
include('thefile.php');
$data = ob_get_contents();
ob_end_clean();
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jul 6th, 2005, 08:20 PM
#7
Thread Starter
Frenzied Member
Re: [ASP]Response.clear >> what is its equivalen in PHP
yup. already turned that on.. for header() to work.
uhm.
about flush() function.. what's its difference with ob_flush()?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|