[wp-trac] [WordPress Trac] #17048: URLs delivered to the browser should be root-relative
WordPress Trac
wp-trac at lists.automattic.com
Fri Oct 28 02:01:41 UTC 2011
#17048: URLs delivered to the browser should be root-relative
-----------------------------+-------------------------
Reporter: dmole | Owner: edwardw
Type: feature request | Status: closed
Priority: normal | Milestone:
Component: General | Version: 3.3
Severity: normal | Resolution: maybelater
Keywords: close |
-----------------------------+-------------------------
Comment (by MarcusPope):
For sending out emails - it's the host that is serving the content. That
will dynamically change depending on where you are hosting from (dev,
staging or production.) So you can safely send out emails from a dev
environment without affecting your production users.
Not changing existing content is a recognized caveat. There are a couple
plugins out there that do accomplish this, and if used in combination with
my plugin they *might* update to root-relative links if they are
implemented properly. Adding a feature to look for a user inputed
"http://internal1.example.com" and replace it with "" in the database
should be doable, but it was outside the scope of what I needed when I
wrote the plugin. As it stands, since the SITE_URL is now dynamic, I
can't reliably know what to look for programmatically because in dev, I
wouldn't know what your production links are supposed to be.
The wlwmanifest is actually pulled from the site_url() - because site_url
is used in ways that are not applicable to root-relative only links it has
to be dynamically generated with the current HTTP_HOST. But it's not a
huge problem because that internal1.example.com will change depending on
the host it is being served from, which is essentially what a root-
relative url does anyway.
It's a shame there's not a comments thread on the plugin page itself, as I
feel awkward posting here for support. Is the only other option my own
solution or constantly trolling the support message board to look for my
plugin's tag?
--
Ticket URL: <http://core.trac.wordpress.org/ticket/17048#comment:54>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list