SlideShare a Scribd company logo
WordPress 3.1
    DC PHP
@nacin
    Andrew Nacin
  andrewnacin.com
nacin@wordpress.org
What’s next?
Post
formats
Admin bar
Internal
 linking
WordPress 3.1 at DC PHP
WordPress 3.1 at DC PHP
WordPress 3.1 at DC PHP
Incremental
improvements
UI & UX
 (always)
AJAX
goodness
WordPress 3.1 at DC PHP
Network
 Admin
WordPress 3.1 at DC PHP
WordPress 3.1 at DC PHP
Taxonomy
 queries
query_posts('cat=123&author=456');	
  

query_posts(array(	
  
	
  	
  'cat'	
  =>	
  123,	
  
	
  	
  'author'	
  =>	
  456,	
  
)	
  );	
  

$myquery['cat']	
  =	
  123;	
  
$myquery['author']	
  =	
  456;	
  
query_posts(	
  $myquery	
  );	
  
And
Tag A and Tag B and Tag C
           Or
Category A or Category B
          Not
Neither Category A nor B
And
  tag__and, category__and
             Or
    tag__in, category__in
            Not
tag__not_in, category__not_in
And across taxonomies
   Tag A and Category B
   Or across taxonomies
    Tag A or Category B
   Not across taxonomies
Neither Tag A nor Category B
$myquery['tax_query']	
  =	
  array(	
  
	
   array(	
  
	
   	
   'taxonomy'	
  =>	
  'category',	
  
	
   	
   'terms'	
  =>	
  array('foo'),	
  
	
   	
   'field'	
  =>	
  'slug',	
  
	
   ),	
  
	
   array(	
  
	
   	
   'taxonomy'	
  =>	
  'post_tag',	
  
	
   	
   'terms'	
  =>	
  array('bar'),	
  
	
   	
   'field'	
  =>	
  'slug',	
  
	
   ),	
  
);	
  
query_posts(	
  $myquery	
  );	
  
$myquery['tax_query']	
  =	
  array(	
  
	
   array(	
  
	
   	
   'taxonomy'	
  =>	
  'category',	
  
	
   	
   'terms'	
  =>	
  array('foo',	
  'bar'),	
  
	
   	
   'field'	
  =>	
  'slug',	
  
	
   	
   'operator'	
  =>	
  'NOT	
  IN',	
  
	
   ),	
  
);	
  
query_posts(	
  $myquery	
  );	
  
$myquery['tax_query']	
  =	
  array(	
  
	
   'relation'	
  =>	
  'OR',	
  
	
   array(	
  
	
   	
   'taxonomy'	
  =>	
  'category',	
  
	
   	
   'terms'	
  =>	
  array('foo'),	
  
	
   	
   'field'	
  =>	
  'slug',	
  
	
   ),	
  
	
   array(	
  
	
   	
   'taxonomy'	
  =>	
  'post_tag',	
  
	
   	
   'terms'	
  =>	
  array('bar'),	
  
	
   	
   'field'	
  =>	
  'slug',	
  
	
   ),	
  
);	
  
query_posts(	
  $myquery	
  );	
  
http://otto42.com/81
   (required reading)
Custom
post types
  register_post_type(	
  'members',	
  
	
  	
  	
  array(	
  
	
   	
   'labels'	
  =>	
  array(	
  
	
   	
   	
   'name'	
  =>	
  'Members',	
  
	
   	
   	
   'singular_name'	
  =>	
  'Member',	
  
	
   	
   	
   ),	
  
	
   	
   'public'	
  =>	
  true,	
  
	
   	
   'show_ui'	
  =>	
  true,	
  
	
   	
   'rewrite'	
  =>	
  array(	
  
	
   	
   	
   'slug'	
  =>	
  'member',	
  
	
   	
   	
   ),	
  
	
   	
   'has_archive'	
  =>	
  true,	
  
	
   )	
  );	
  
  register_post_type(	
  'members',	
  
	
  	
  	
  array(	
  
	
   	
   'labels'	
  =>	
  array(	
  
	
   	
   	
   'name'	
  =>	
  'Members',	
  
	
   	
   	
   'singular_name'	
  =>	
  'Member',	
  
	
   	
   	
   ),	
  
	
   	
   'public'	
  =>	
  true,	
  
	
   	
   'show_ui'	
  =>	
  true,	
  
	
   	
   'rewrite'	
  =>	
  array(	
  
	
   	
   	
   'slug'	
  =>	
  'member',	
  
	
   	
   	
   ),	
  
	
   	
   'has_archive'	
  =>	
  'team',	
  
	
   )	
  );	
  
/team/
/member/nacin/

archive-­‐members.php	
  
single-­‐members.php	
  
Have fun
breaking
WordPress
Beta 2 will
be released
 tomorrow

More Related Content

PDF
Taking Perl to Eleven with Higher-Order Functions
PPT
An Elephant of a Different Colour: Hack
PDF
画像Hacks
PDF
Why Hacking WordPress Search Isn't Some Big Scary Thing
PPTX
Building Your First Widget
PDF
introduction to Django in five slides
PDF
Automatically Spotting Cross-language Relations
Taking Perl to Eleven with Higher-Order Functions
An Elephant of a Different Colour: Hack
画像Hacks
Why Hacking WordPress Search Isn't Some Big Scary Thing
Building Your First Widget
introduction to Django in five slides
Automatically Spotting Cross-language Relations

What's hot (20)

TXT
Codigos
PDF
4.1 PHP Arrays
PDF
WordPress Cuztom Helper
TXT
Daily notes
PDF
2013 28-03-dak-why-fp
PDF
好みの日本酒を呑みたい! 〜さけのわデータで探す自分好みの酒〜
PDF
令和から本気出す
RTF
KEY
Extending Moose
PDF
Make your own wp cli command in 10min
PPTX
Laravel
PDF
{tidygraph}と{ggraph}による モダンなネットワーク分析(未公開ver)
PDF
Webmontag Berlin "coffee script"
PDF
Magicke metody v Pythonu
PDF
CakePHPをさらにDRYにする、ドライケーキレシピ akiyan.com 秋田真宏
PDF
Devs for Leokz e 7Masters - WTF Oriented Programming
PDF
Closure, Higher-order function in Swift
PDF
The Magic Of Tie
ODP
PDF
PHP tips and tricks
Codigos
4.1 PHP Arrays
WordPress Cuztom Helper
Daily notes
2013 28-03-dak-why-fp
好みの日本酒を呑みたい! 〜さけのわデータで探す自分好みの酒〜
令和から本気出す
Extending Moose
Make your own wp cli command in 10min
Laravel
{tidygraph}と{ggraph}による モダンなネットワーク分析(未公開ver)
Webmontag Berlin "coffee script"
Magicke metody v Pythonu
CakePHPをさらにDRYにする、ドライケーキレシピ akiyan.com 秋田真宏
Devs for Leokz e 7Masters - WTF Oriented Programming
Closure, Higher-order function in Swift
The Magic Of Tie
PHP tips and tricks
Ad

Similar to WordPress 3.1 at DC PHP (20)

PDF
WP_Query, pre_get_posts, and eliminating query_posts()
PDF
Dig Deeper into WordPress - WD Meetup Cairo
PDF
WordPress Queries - the right way
ODP
Session taxonomies
PPTX
Victoria wordpress
KEY
Dev Theming
KEY
Theme Development from the Coding End
PPTX
Parsing strange v3
PDF
Parsing strange v3
KEY
What's New in WordPress 3.0 (for developers)
KEY
The Query the Whole Query and Nothing but the Query
PPTX
Parsing strange v4
PDF
Parsing strange v4
PDF
You Don't Know Query (WordCamp Netherlands 2012)
PPTX
WordPress for developers - phpday 2011
PDF
Parsing strange v2
PPTX
Parsing strange v1.1
PPTX
Your New BFFs: The WordPress Core Tables + The MySQL Database
PPTX
The WordPress University 2012
PDF
You Don't Know Query - WordCamp Portland 2011
WP_Query, pre_get_posts, and eliminating query_posts()
Dig Deeper into WordPress - WD Meetup Cairo
WordPress Queries - the right way
Session taxonomies
Victoria wordpress
Dev Theming
Theme Development from the Coding End
Parsing strange v3
Parsing strange v3
What's New in WordPress 3.0 (for developers)
The Query the Whole Query and Nothing but the Query
Parsing strange v4
Parsing strange v4
You Don't Know Query (WordCamp Netherlands 2012)
WordPress for developers - phpday 2011
Parsing strange v2
Parsing strange v1.1
Your New BFFs: The WordPress Core Tables + The MySQL Database
The WordPress University 2012
You Don't Know Query - WordCamp Portland 2011
Ad

More from andrewnacin (16)

PDF
Challenges Building the WordPress REST API (API Strategy & Practice, Chicago ...
PDF
WordCamp Netherlands 2012: WordPress in 2012
PDF
WordCamp SF 2011: Debugging in WordPress
PDF
WordCamp San Francisco 2011: Transients, Caching, and the Complexities of Mul...
PDF
Open Source (and you can too) - 2011 Teens in Tech Conference
PDF
WordCamp Columbus 2011 - What's Next for WordPress
PDF
TEDxYouth@DowntownDC
PDF
Best Practices in Plugin Development (WordCamp Seattle)
PDF
Ask Not What WordPress Can Do For You (Ignite - WordCamp Seattle)
PDF
Hidden Features (WordPress DC)
PDF
Lightning Talk: Mistakes (WordCamp Phoenix 2011)
PDF
WordPress at Web Content Mavens (Jan. 2011)
PDF
What's Next for WordPress at WordCamp Netherlands
PDF
What's Next for WordPress: WordCamp Birmingham 2010
PPTX
WordPress 3.0 at DC PHP
PPT
Advanced and Hidden WordPress APIs
Challenges Building the WordPress REST API (API Strategy & Practice, Chicago ...
WordCamp Netherlands 2012: WordPress in 2012
WordCamp SF 2011: Debugging in WordPress
WordCamp San Francisco 2011: Transients, Caching, and the Complexities of Mul...
Open Source (and you can too) - 2011 Teens in Tech Conference
WordCamp Columbus 2011 - What's Next for WordPress
TEDxYouth@DowntownDC
Best Practices in Plugin Development (WordCamp Seattle)
Ask Not What WordPress Can Do For You (Ignite - WordCamp Seattle)
Hidden Features (WordPress DC)
Lightning Talk: Mistakes (WordCamp Phoenix 2011)
WordPress at Web Content Mavens (Jan. 2011)
What's Next for WordPress at WordCamp Netherlands
What's Next for WordPress: WordCamp Birmingham 2010
WordPress 3.0 at DC PHP
Advanced and Hidden WordPress APIs

WordPress 3.1 at DC PHP