[mythtv-users] Absolute links in mythweb
Michael T. Dean
mtdean at thirdcontact.com
Thu Apr 6 00:44:58 UTC 2006
On 04/05/2006 05:54 PM, Ben Holt wrote:
>>>I don't understand how PHP running on my mythtv server's apache is
>>>supposed to detect that it is being accessed from a reverse proxy and
>>>auto-detect the URL requested on the proxy. It can look at it's own
>>>$_SERVER array and figure out where it lives in its own directory
>>>structure relative to DocumentRoot, but that's it. For all PHP knows
>>>the reverse proxy is just another browser asking for an URL.
>>>
>>Which is why you need to have the proxy server fix it /before/ it gets
>>to your Myth box... See http://apache.webthing.com/mod_proxy_html/ .
>>
>I understand what you're saying. Yes the problem could be
>
^H^H^H^H^H^H^H^Hshould be ;)
> fixed at the
>proxy, but from my perspective that's not where it originates. It's
>the absolute URLs in mythweb that are causing the problem. The best
>fix is to undo the use of fake directories for passing variables in
>mythweb.
>
So, you're saying that Chris should undo all the work he's done on
MythWeb since 0.18 (all the work to change to the rewrite approach)
because you're unwilling to admit that having your proxy change a
request for "/whatever" (used by the internal network--mythserver) to
"/mythtv/whatever" (used by the external network--externalserver) is the
right solution?
Or, you could install MythWeb on your Myth box to
"http://mythserver/mythtv/" so that your external server (which uses
"http://externalserver/mythtv/") uses the same directory structure. I
run my system like that and it works without any issues.
If you do this and you really need the internal network to see MythWeb
using just "http://mythserver/", set up a welcome file to redirect to
"http://mythserver/myth/" or set up a virtual host to redirect (or both):
<VirtualHost *:80>
ServerName mythtv.mythserver
ServerAdmin webmaster at mythserver
Redirect permanent / http://mythserver/mythtv/
</VirtualHost>
> Then it goes back to "just working" using relative URLs and
>regardless of where it is installed in a web server's directory
>structure.
>
Good luck convincing Chris that everything he's done since 0.18 needs
undone. (And, by that I'm not saying that Chris is unreasonable...)
IMHO, 0.19's MythWeb is a huge step up from 0.18's.
> Admitedly my own personal bias comes into this and I'd
>rather spend a bit more time fixing mythweb the way I want it than
>working around it elsewhere.
>
>Anyway, I'll shut up and not complain until I've got a "fix" worth
>sharing. Until then it's ssh and links for me :-).
>
Probably the quickest way to get a "fix" is to get a reverse diff
between current SVN and 0.18.1...
Mike
More information about the mythtv-users
mailing list