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
檢視更多 >