protected function escape_url($url) {
        $url = str_replace('"', '%22', $url);
        $url = str_replace('\'', '%27', $url);
        $url = str_replace(' ', '%20', $url);
        $url = str_replace('<', '%3C', $url);
        $url = str_replace('>', '%3E', $url);
        return $url;
    }