Questions tagged [site-url]

The site_url template tag retrieves the (admin/backend) site url for the current site (where the WordPress core files reside) with the appropriate protocol, 'https' if is_ssl() and 'http' otherwise.

Filter by
Sorted by
Tagged with
10
votes
1answer
485 views

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 ...
78
votes
6answers
117k views

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 ...
4
votes
4answers
3k views

how to use a different domain/subdomain for authors/catagories on single site?

I'm not sure if I phrased this question correctly... My wife and I have one blog, family.com in this example, that we both contribute to. I would like family.com to show all blog posts. me.family....
3
votes
1answer
29k views

Login to wp-admin “redirect_to” points to wrong URL after migration

I have a WordPress site hosted on GoDaddy, it's a Windows server, (i have the web.config set up). and .htaccess correctly configured. The site was working on example.com/wordpress , as it was a ...
12
votes
4answers
21k views

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?
16
votes
5answers
59k views

When moving a WP site, why does wp-admin redirect to old site?

I am in the process of moving a WP site from one host to another. I copied the database and all the files, created a new database and imported the old one. I then changed the wp-config file. The home ...
1
vote
1answer
2k views

Remove HTTP: from the site URL and just keep // in it

I am building a website for my company which loads over HTTP inside the company and over HTTPS outside company's network. This is a compulsion and there is no way we can avoid it. The site needs to ...
0
votes
3answers
2k views

URL rewriting for WordPress Network (Multisite) subsite

We have an install of WordPress Network (Multisite) that has multiple blogs running under the url blogs.exampleurl.com where each subsite is blogs.exampleurl.com/site1 /site2 etc... We have a user ...
0
votes
1answer
9k views

Change homepage url

is there any way how to achieve this? I've tried to google it, but I have no clue how to call it. siteurl.com - for whole web siteurl.com/news - homepage with news When I add siteurl.com I have to ...
0
votes
1answer
1k views

(How) Can I change my Multisite Network to use a different blog as Primary?

Here's my basic setup: http://my.domain.com/ - The "primary blog" or "Network" http://my.domain.com/blogone/ - A sub-site or "blog" http://my.domain.com/blogtwo/ - Same, obviously ...
0
votes
1answer
999 views

Changing www prefix in General Settings and Interior Links

This may be the most redundant/dumbest question known to man, but if I go into Wordpress' General Settings and modify my Site Url to include a www, so http://mysite.com becomes http://www.mysite....
4
votes
6answers
11k views

How do I change the Multisite URL?

The links in the navbar menu, in (My sites > Manage the network) are pointing (and keep redirecting) to incorrect URLs. The incorrect URLs are in this pattern: https://https//www.domain.com/wp-admin/...
1
vote
2answers
1k views

get url page template

I have created a page template where I need current page URL I have tried get_site_url(); and get_permalink(); but it shows nothing. Let me know is anything missing in code.
1
vote
3answers
3k views

How to get rid of index.php?

Does anyone know how I can get rid of index.php in my URL? Right now if I add a new page, the address will be: www.mywebsite.com/index.php/page1 But I want it to be: wwww.mywebsite.com/page1 I ...
1
vote
1answer
627 views

Login redirect_to loop with reauth=1, cookie expiry set to 1 year in past

(I've resolved this - sequencing error in wp-config.php - thanks to this answer elsewhere). I've moved a site dev to production and everything is working correctly except the login form, which is ...
1
vote
1answer
419 views

What does $scheme in site_url function do?

Could someone tell me what the $scheme precisely does in the site_url function? What does it provide and how to use it? Of course I have read the Codex, but since I am not a native English speaker, ...
1
vote
1answer
165 views

Do I need to use the esc_html() function on hard coded links?

I understand when using certain WP functions like site_url(); you should escape these with the esc_html(); function in the following manner: <?php esc_html(site_url()) ?> My question is, if I ...
0
votes
4answers
6k views

WP redirects all pages from new domain to old domain

I've moved my Wordpress installation from my development domain to the live domain, but it keeps redirecting every page back to the old (dev) domain. So far I've: Added define('WP_HOME', 'http://...
0
votes
1answer
87 views

redirect 301 old url to new url

I created a custom post type (collections) and taxonomy (collection_categories) with 4 terms (paintings, drawings, sculptures, past sales), now I want to change my site url, old url is www....
0
votes
1answer
129 views

Sub-domain or 2nd, temporary different domain?

I'm developing a Wordpress site for a website that already exists (that's not currently using Wordpress). The current website cannot be taken down until the new Wordpress site is ready to replace it. ...