How to get the blog domain?
-
Hi!
Is there a function to return only the blog domain, not the whole blog URL?
I couldn’t find one in the Function Reference.
EXAMPLE:
<?php echo get_wp_domain(); ?>
Output: example.com
Or do I have to cut the first eleven characters of the home_url?
<?php echo substr(home_url(), 11); ?>
Output: example.com
Kind regards
Hugo
- The topic ‘How to get the blog domain?’ is closed to new replies.