-
PHP output
Is there a way to manipulate the php output before it's loaded, like for instance, I made a php script that parses xml data, gets info on local files etc, and it's all separate variables. I was wondering if the data to be echoed is stored in a variable or something so I can encode the data into a javascript document.write just before the page actually loads without having to manually encode each variable echoed.
-
I don't get what you want.
What do you mean?
Any examples?
-
<?php
include 'random_file_of_stuff.html';
echo "<br><br>"
$PHP_OUTPUT = rawurlencode($PHP_OUTPUT)
?>
the php output is the fictional variable I'm looking for, but coming to think of it, there's probably nothing like that at all.
-
sounds like you could make a function for it if your extremely advanced. :p
-
No, there is no PHP output variable. Why don't you just read everything into a string instead of printing it out?