Forum OpenACS Q&A: Response to host / site-node map

Collapse
Posted by Ben Adida on
Alex,

I'm worried that my patches have repercussions that I haven't yet seen. Screwing with the request processor is no small thing, and I want to make sure things work before I commit.

That said, here is the patch file that you can test out, too, if you want. You have to run patch -p0 on it while in the packages/acs-tcl directory.

Index: tcl/request-processor-procs.tcl
===================================================================
RCS file: /cvsroot/openacs-4/packages/acs-tcl/tcl/request-processor-procs.tcl,v
retrieving revision 1.25
diff -r1.25 request-processor-procs.tcl
902c902,907
<       set url "[ad_conn url]/"
---
>         # Ben's hack to make this work with host-based stuff
>         set whole_url [ad_conn url]
>         set root [root_of_host [ad_host]]
>         regsub "^$root" $whole_url "" host_url
>
>       set url "$host_url/"
906c911
<
---
>
Index: tcl/utilities-procs.tcl
===================================================================
RCS file: /cvsroot/openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl,v
retrieving revision 1.18
diff -r1.18 utilities-procs.tcl
2537a2538,2542
>    # Ben's hack
>     set root [root_of_host [ad_host]]
>     regsub "^$root" $path "" path
>
>