network_by_path_segments_count

过滤钩子
apply_filters( 'network_by_path_segments_count', $segments, $domain, $path )
参数
  • (int|null) $segments The number of path segments to consider. WordPress by default looks at one path segment. The function default of null only makes sense when you know the requested path should match a network.
    Required:
  • (string) $domain The requested domain.
    Required:
  • (string) $path The requested path, in full.
    Required:
定义位置
相关勾子
site_by_path_segments_countnetwork_allowed_themesnetwork_admin_menunetwork_home_urlpre_get_network_by_path
相关方法
get_network_by_pathwp_update_comment_countget_attachment_iconnetwork_home_urlget_comment_countnetwork_admin_url
引入
3.9.0
弃用
-

network_by_path_segments_count: 这是一个函数,用于返回与特定路径相关的网络,由URL中的路径段数量定义。

过滤搜索站点时要考虑的路径段数。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
$segments = apply_filters( 'network_by_path_segments_count', $segments, $domain, $path );
$segments = apply_filters( 'network_by_path_segments_count', $segments, $domain, $path );
$segments = apply_filters( 'network_by_path_segments_count', $segments, $domain, $path );

常见问题

FAQs
查看更多 >
闪电伯伯

(工作日 10:00 - 18:30 为您服务)

2025-11-18 23:27:38

您好,无论是售前、售后、意见建议……均可通过联系工单与我们取得联系。

您也可选择聊天工具与我们即时沟通或点击查看:

您的工单我们已经收到,我们将会尽快跟您联系!
取消
选择聊天工具: