Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news-1.dfn.de!news.dfn.de!news.informatik.hu-berlin.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Nigel Wade Newsgroups: comp.lang.java.programmer Subject: Re: URLEncoder and # Date: Wed, 18 Jun 2014 11:30:23 +0100 Lines: 19 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net kdDW6oaR7X9yqEQTCkIwuAUHD9vZTAaSj8yZsZnl22UuYVP52a Cancel-Lock: sha1:uKTZB5UkPaeV7iWWS6vhHUBmpLk= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 In-Reply-To: Xref: csiph.com comp.lang.java.programmer:28769 On 18/06/14 10:37, Roedy Green wrote: > It seems URLEncoder converts # to %23 > > Why would there be any need to encode it? Because # is a special character in a URI. It separates the main URI from a fragment suffix. Have you never used "NAME" tag in your web pages to identify sub-sections? The browser shouldn't send anything after a # in a request, it's used by the browser to identify a fragment within the returned page. The URI specification should satisfy your curiosity. > > The AppVisor people are complaining about URLs containing # saying > they need to be URLEncoded. Surely that is not true. > I think it probably is true.