From mboxrd@z Thu Jan 1 00:00:00 1970 Received-SPF: None (mailfrom) identity=mailfrom; client-ip=8.23.224.60; helo=out.smtp-auth.no-ip.com; envelope-from=kevin@carhart.net; receiver= Received: from out.smtp-auth.no-ip.com (smtp-auth.no-ip.com [8.23.224.60]) by hurricane.the-brannons.com (Postfix) with ESMTPS id 43B36788C0 for ; Fri, 25 May 2018 16:50:13 -0700 (PDT) X-No-IP: carhart.net@noip-smtp X-Report-Spam-To: abuse@no-ip.com Received: from carhart.net (unknown [99.52.200.227]) (Authenticated sender: carhart.net@noip-smtp) by smtp-auth.no-ip.com (Postfix) with ESMTPA id 585E0353 for ; Fri, 25 May 2018 16:50:16 -0700 (PDT) Received: from carhart.net (localhost [127.0.0.1]) by carhart.net (8.13.8/8.13.8) with ESMTP id w4PNoDuL019449 for ; Fri, 25 May 2018 16:50:13 -0700 Received: from localhost (kevin@localhost) by carhart.net (8.13.8/8.13.8/Submit) with ESMTP id w4PNoBp6019377 for ; Fri, 25 May 2018 16:50:13 -0700 Date: Fri, 25 May 2018 16:50:11 -0700 (PDT) From: Kevin Carhart To: edbrowse-dev@lists.the-brannons.com Subject: [edbrowse-dev] another encoding question Message-ID: User-Agent: Alpine 2.03 (LRH 1266 2009-07-14) X-BeenThere: edbrowse-dev@edbrowse.org List-Id: Edbrowse Development List MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Around February I was trying to add urlencode() calls to the XHR code and try to say "this needs a call because it's not encoded yet." At that time, Karl sez: > I take issue with your encoded decoded test, because I've been down > that path before. > There is simply no way to tell if a url is encoded. So acknowledging this, I am wondering if there is something we can do about the following xhr call from radio caroline, and any others that would be on this pattern. It doesn't work with a space and it does work with a %20. xhr http://radiocaroline.co.uk/website_prefs.json?v=2018-05-25 23:31:19.890+00:00 curl> GET /website_prefs.json?v=2018-05-25 23:31:19.890+00:00 HTTP/1.1 Host: radiocaroline.co.uk curl< HTTP/1.1 400 Bad Request --- When I just go to startwinow, replace spaces with %20 just before fetchHTTP and recompile, the load of website_prefs succeeds and this triggers a whole bunch of new things like the long list of available 'g' links to different sections. (Whether the links work is another matter but when website_prefs succeeds, at least they render in the first place.) xhr http://radiocaroline.co.uk/website_prefs.json?v=2018-05-25%2023:33:04.754+00:00 curl> GET /website_prefs.json?v=2018-05-25%2023:33:04.754+00:00 HTTP/1.1 Host: radiocaroline.co.uk curl< HTTP/1.1 200 OK