network_home_url()返回首页网址(多站点)

目录

描述

The network_home_url template tag retrieves the home url for the current network with the appropriate protocol, 'https' if is_ssl() and 'http' otherwise. If scheme is 'http' or 'https', is_ssl() is overridden.

In case of non network setup, use home_url() instead.

network_home_url() 描述

用法

<?php network_home_url$path$scheme ); ?>

network_home_url() 用法

参数

$path

(string) (可选) Path relative to the home url.

默认值: None

$scheme

(string) (可选) Scheme to give the home url context. Currently 'http','https'.

默认值: null

network_home_url() 参数

注意

相关