realtime output for xcat command

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@13515 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
xq2005 2012-08-15 12:52:39 +00:00
parent acaefeedda
commit 83e88eac4b

View File

@ -111,11 +111,13 @@ function submit_request($req, $skipVerify, $opts_array){
// Flush output to browser
if ($flush) {
// Strip HTML tags from output
$str = preg_replace('/<errorcode>.*<\/errorcode>/', '', $str);
if ($tmp = trim(strip_tags($str))) {
// Format the output based on what was given for $flush_format
if ($flush_format == "TDB") {
format_TBD($tmp);
} else {
$tmp = preg_replace('/\n\s*/', "\n", $tmp);
// Print out output by default
echo '<pre style="font-size: 10px;">' . $tmp . '</pre>';
ob_flush();