added escape function.