public static function SanitizeOutput($sBuffer) {
            $oThis = self::CreateInstanceIfNotExists();

            $aSearch = array('/\>[^\S ]+/s',
                             '/[^\S ]+\</s',
                             '/(\s)+/s'
                            );

            $aReplace = array(
                            '>',
                            '<',
                            '\\1'
                            );

            $oThis->sBuffer = preg_replace($aSearch, $aReplace, $sBuffer);
        }