I opened a ticket about. Clearly storing URLs in data attributes gets 
ignored by Proxies.

On Thursday, 14 November 2013 17:46:42 UTC-6, DeanK wrote:
>
> I'm having trouble with a web2py site sitting behind an Apache2 reverse 
> proxy that uses web2py's built in ajax capability.  The main domain server 
> configuration is setup like this to point to the server running my web2py 
> app:
>
> ProxyHTMLInterp On
> LogLevel Debug
> ProxyHTMLLogVerbose On
> ProxyPass /link/ http://my.server.com/
> ProxyPassReverse /link/ http://my.server.com/
>
> ProxyHTMLURLMap http://my.server.com /link/
>
> <Location /stem/>
>    ProxyPassReverse /
>    SetOutputFilter  proxy-html
>    ProxyHTMLURLMap http://my.server.com /link/
>    ProxyHTMLURLMap / /link/
>    ProxyHTMLURLMap  /link/ /link/
>    RequestHeader    unset  Accept-Encoding
> </Location>
>
> So now if I go to http://maindomain.com/link/ it loads my web2py app from 
> http://my.server.com
>
> With this configuration things more or less appear to work for http right 
> now (i still need to sort out https).  The only issue is all of my ajax 
> calls that use web2py's built in LOAD() function break.  I'm thinking this 
> is because proxy_html doesn't recognize the ajax call in the html to 
> rewrite it due to how web2py does things?
>
> view snippet:
> ....
>
> <div id="project1">{{=LOAD('project','project_grid.load', 
> ajax=True,ajax_trap=True,user_signature=True,target="project1")}}</div> 
>
> ....
>
>
> html after proxy:
> ...
>
> <div id="project1"><div data-w2p_remote="
> /myapp/project/project_grid.load?_signature=f9f89cf781972e66ed34841f00c3250686653cbc"
>  
> id="project1">loading...</div></div> 
>
> ...
>
>
> here if the url rewrite worked this should have pointed to 
> /link/myapp/project/project_grid.load
>
>
>
> Anyone have any experience with this?  Is there somehow i can tell web2py 
> to add the prefix for only the LOAD() methods or something? Thanks.
>
>
>
>
>
>
>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to