WordPress.org
News
Showcase
Hosting
Extend
Themes
Plugins
Patterns
Blocks
Openverse
↗
︎
Learn
Learn WordPress
Documentation
Forums
Developers
WordPress.tv
↗
︎
Community
Make WordPress
Photo Directory
Five for the Future
Events
Job Board
↗
︎
About
About WordPress
Enterprise
Gutenberg
↗
︎
Get WordPress
Search Trac
Get WordPress
Make WordPress Core
Blog
Handbook
Tickets
Components
Browse Source
Trac Timeline
Create a New Ticket
Search:
Login
Notifications
Context Navigation
Back to Ticket #9674
Ticket #9674
: post-type.php
File post-type.php,
223 bytes
(added by
ryan
,
15 years ago
)
Test plugin, drop in mu-plugins dir
Line
1
<?php
2
3
function
post_type_thingy
()
{
4
register_post_type
(
'thingy'
,
array
(
'label'
=>
__
(
'Thingies'
),
'public'
=>
true
)
);
5
register_taxonomy_for_object_type
(
'post_tag'
,
'thingy'
);
6
}
7
8
add_action
(
'init'
,
'post_type_thingy'
);
Trac UI Preferences
Download in other formats:
Original Format