Forum OpenACS Development: Re: rp_handler and host-node mapped subsites

Collapse
Posted by Ryan Gallimore on
OK, I agree. We need to alter ad_conn url* in the case of host-node mapped subsites, then. If we did that in this case, the RP redirect would not be necessary.

Any thoughts?

Collapse
Posted by Torben Brosten on
Insert the value from site_node::conn_url when ad_conn url is from a host node mapped site?

This would be the simplest solution, but doesn't work for all cases, because sometimes ad_conn url is used to build a reference only available from the main domain.

The alternative is to swapp ad_conn url with site_node::conn_url for the specific cases that do work.

Collapse
Posted by Dave Bauer on
Any references available ONLY from the main domain are also bugs.

See new embeds APM feature (i'll try to find a link to more info) which should resolve this issue by allowing search/notification and other site-wide services to be embedded in the subsite context.

Collapse
Posted by Ryan Gallimore on
How does using embed for those specific services fix the general problem when I access http://mapped/page and [ad_conn url] returns /mapped/page? Shouldn't we fix ad_conn url to show the proper URL: /page?
Collapse
Posted by Dave Bauer on
Those are two different issues. ad_conn url should return the URL you actually used to access the page.
Collapse
Posted by Torben Brosten on
It would be nice to finally fix ad_conn url for host node mapping cases.

It's been a couple of years since I've been messing with host node mapping.

Apparently site_node::conn_url isn't a direct substitute as I mentioned. I'm terribly sorry about spouting that without re-checking.

site_node::conn_url is a proc for building urls that work when ad_conn url breaks for host node mapping.

One can use site_node::conn_url to generate urls that work with or without hostnode mapping, so that a host node mapped site works from the main domain as well.

Using site_node::conn_url is really useful when the main domain has a ssl/https setup, because the site can switch back and forth between http/https without generating a security warning or changing the display templates. You can direct a user to login via https and then switch them back to http on the hostnode mapped subsite after login. The UI flow is smooth.