Opened 16 years ago
Closed 16 years ago
#12918 closed defect (bug) (fixed)
Register default post types before plugins and themes are loaded
| Reported by: | ryan | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.0 |
| Component: | Posts, Post Types | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: |
Description
Although correct behavior is to wait until init has fired to do anything, many themes call get_pages() prior to init. If the default post types have not been registered yet, get_pages() will fail because the "page" post type is not present. We can work around this in the same manner as we did for taxonomies by calling create_initial_post_types() before loading plugins and themes.
Attachments (1)
Change History (4)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Works for me. Closing #12873 as a duplicate.