+// Merges HTTP header lines with given body (string)
+function mergeHttpHeadersWithBody ($body) {
+ // Add empty entry to mimic header->body
+ $GLOBALS['http_headers'][] = getConfig('HTTP_EOL');
+
+ // Make sure at least one header is there (which is still not valid but okay here)
+ assert((is_array($GLOBALS['http_headers'])) && (count($GLOBALS['http_headers']) > 0));
+
+ // Merge both together
+ return merge_array($GLOBALS['http_headers'], array(count($GLOBALS['http_headers']) => $body));
+}
+