Opened 8 years ago
Closed 8 years ago
#38039 closed enhancement (fixed)
Invalid PHPDOC for get_sites
Reported by: | MaximeCulea | Owned by: | DrewAPicture |
---|---|---|---|
Milestone: | 4.7 | Priority: | normal |
Severity: | normal | Version: | 4.6.1 |
Component: | Networks and Sites | Keywords: | has-patch |
Focuses: | docs, multisite | Cc: |
Description
It seems that the PHPDOC for get_sites
is invalid.
While it is written that the $network_id
arg allows to Limit results to those affiliated with a given network ID. Default current network ID..
In fact if we look closely to WP_Site_Query
and his $network_id
arg, it is specified that Limit results to those affiliated with a given network ID. If 0, include all networks. Default 0..
So when using get_sites
with no network_id given, it will not return sites from the current network but from all networks.
Attachments (1)
Change History (5)
Note: See
TracTickets for help on using
tickets.
Thanks for the patch @MaximeCulea!