private function quoteString($string) { return '"' . str_replace(array('\\', '"'), array('\\\\', '\\"'), $string) . '"'; }