I’ve got a $$Return field set up so that when a response document it closed, the browser returns to the parent document. All well and good so far, but I’d like to return to a particular spot on the parent document using an anchor. The anchor appears in the computed $$Return value, and if I type in the URL I want (db.nsf/viewid/docid#anchor), I end up where I want to be, but when I actually save the document, the anchor is truncated, and I’m sent back to the top of the document. I’ve found nothing in the documentation about this, but a three-year-old post here suggests that you can’t use anchors with $$Return. Does anyone know if this is, in fact, the case? Is there any way to make this work?
Subject: Anchors and $$Return
You might escaping it some way. Maybe like "#'. Maybe with HTML (similar to ).
Subject: RE: Anchors and $$Return
I think it may be something fundamental in how Domino handles redirection. The
string is being properly generated; the anchor just gets chopped off when it’s
handed to the web browser, either from $$Return or, as I’ve discovered, from
within a LotusScript agent.
What I’ve done, in case anyone is interested, is to take redirection out of the
hands of the server. Instead of using $$Return, I created an agent run on
WebQuerySave. The agent creates the appropriate URL, complete with anchor, but
instead of redirecting to that URL directly, it creates a bit of Javascript
which uses that URL for its own redirection, kinda like this:
the_url = “http://server/file.nsf/view/unid#anchor”
print |script language=javascript>window.navigate(‘| + the_url +
|’)]|