/ Published in: PHP

i know these regex stuff is rather slow, but still i like having slim documents. (don't forget to use gzip compression on all text docs)
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
/** * @param $string (X)HTML document string * @return string * @todo benchmark/optimize performance */ private function minimizeHTML($string) { // will remove tabs, line breaks and extra white spaces /','/\t/'),'',$string); return $r; }
Comments
