Geert, I get the same result.
Also not that the same thing happens if it is a & instead of a # in the parameter value. Neil. on 12/10/15 9:46 AM, Geert Josten <[email protected]> wrote: > Hi Neil, > > What happens if you skip the url-decode? That should be unnecessary. Leave > the url-encode in place though.. > > Kind regards, > Geert > > On 10/12/15, 10:39 AM, "[email protected] on behalf > of "neil bradley"" <[email protected] on behalf of > [email protected]> wrote: > >>I think there is a bug in xdmp:get-request-field() when the parameter >>contains a # character, even when it is URL-encoded. It seems that the >>code that returns the parameter value assumes that # terminates the >>value. And it still happens even if I add another # at the end of the >>URL. >> >>Here is some code that illustrates the issue: >> >> xdmp:set-response-content-type("text/html") >> , >> <html> >> <body> >> <p><a >>href="TestHash.xqy?Param={xdmp:url-encode('abc#def')}#x">abc#def</a></ >>p> >> <p>Param = >>{xdmp:url-decode(xdmp:get-request-field("Param"))}</p> >> </body> >> </html> >> >>When I click on the link, I see the expected URL in the browser: >> >> http://localhost:8040/TestHash.xqy?Param=abc%23def#x >> >>Yes the displayed shows that the "#def" part of the value is missing:: >> >> Param = abc >> >>Any ideas? Is this a bug or am I missing something? >>_______________________________________________ >>General mailing list >>[email protected] >>Manage your subscription at: >>http://developer.marklogic.com/mailman/listinfo/general > > > > _______________________________________________ General mailing list [email protected] Manage your subscription at: http://developer.marklogic.com/mailman/listinfo/general
