Home / PHP Tips Generated By ChatGPT / Using Output Buffering in PHP Capture output before sending it to the browser, allowing for manipulation or conditional sending. Source Code ob_start(); echo "Hello, World!"; $output = ob_get_clean(); echo strtoupper($output); // Outputs: HELLO, WORLD!