wp_is_home_url_using_https()
Checks whether the current site URL is using HTTPS.
No Hooks.
Return
true|false
. True if using HTTPS, false otherwise.
Usage
wp_is_home_url_using_https();
Notes
- See: home_url()
Changelog
Since 5.7.0 | Introduced. |
wp_is_home_url_using_https() wp is home url using https code WP 6.6.2
function wp_is_home_url_using_https() { return 'https' === wp_parse_url( home_url(), PHP_URL_SCHEME ); }