Prevent “main” WPMU site_url() being returned in functions

I’ve noticed that in a WordPress MU install with domain mapping enabled, some functions return URIs that don’t use the current WPMU site’s primary domain name which possibly means they are “WPMU Domain Mapped-ignorant functions” (a little harsh, I know). What can I do to ensure the primary domain of the current WPMU site is … Read more

Two (or more) parallel (sub-)TLDs that are retained when surfing the site / dynamically set the site address?

I am running a site for a German NGO under the domain sub.example.org. Recently, I added sub.example.ch for its Swiss spin-off. Both (sub-)domains are pointing to the same physical location, a WP install (not multisite). I have it setup such that sub.example.ch/register, for instance, will correctly show the content found under sub.example.org/register. However, when a … Read more

What is difference between get_bloginfo(‘url’) and get_site_url()?

I am developing a plugin. I want to know difference between get_bloginfo(‘url’); and get_site_url(); I got same output, then what’s the difference? 4 get_bloginfo(‘url’) calls home_url() calls get_home_url() reads option home get_bloginfo(‘wpurl’) calls site_url() calls get_site_url() reads option siteurl get_bloginfo(‘siteurl’) and get_bloginfo(‘home’) are deprecated arguments and return get_bloginfo(‘url’) (siteurl argument is documented wrong in Codex … Read more

What’s the difference between home_url() and site_url()

My understanding is that site_url() returns the location where the WordPress core files are. If my blog is hosted at http://example.com/blog then site_url() returns http://example.com/blog But then how does home_url() differ? For me, home_url() returns the same thing: http://example.com/blog If that’s correct, then can I get WordPress to return http://example.com/ ? You are asking two … Read more