SlideShare a Scribd company logo
1 of 44
Pods + WP = CMS Sort of …
What do we want in a CMS? Flexible – Does different things	 Robust – Does things well
Is Wordpress a CMS? Yes Wordpress is really good at publishing one kind of content: the Post Its interface is easy to learn and easy to teach.  Theming is especially powerful. Design community Plugins and custom fields provide additional flexibility on a post by post basis.
Is Wordpress a CMS? No	 Major challenges customizing backend UI All post types essentially the same Custom fields difficult to work with in complex ways Scalability issues
So what? Time is money Consultants need to maximize functionality/time equation.
Custom Fields Good for on the fly customization Bad for complex content types
Querying Custom Fields $args = “meta_key=airline_name&value=American”; $args = “meta_key=arrives&meta_compare=>=&meta_value=DATE()” query_posts($args);
Multiple custom fields? function get_post_meta_multiple($metaDataList) { 	global $wpdb; 	$querystr = "SELECT p.* FROM $wpdb->posts AS p WHERE p.ID IN ( "; 	$querystr .= "SELECT post_id FROM $wpdb->postmeta WHERE "; 	$innerqry = array(); foreach($metaDataList as $key => $value) { 		$innerqry[] = $wpdb->prepare( "(meta_key = %s AND meta_value = %s)", $key, $value );	 	} 	$querystr .= implode(" OR ", $innerqry); 	$querystr .= " GROUP BY post_id "; 	$querystr .= "HAVING count(*) = " . count($metaDataList); 	$querystr .= ") AND p.post_status = 'publish' "; 	$metaResults = $wpdb->get_results($querystr, OBJECT);					 	return $metaResults; } Source: http://tinyurl.com/ldadam
Scalability Most wordpress users will never experience performance issues because the number pages just isn’t enough to matter.  But consultants still need to be concerned.
Scalability All posts/types are in one table. All custom fields are in longtext format which means they can store up to 4GB. Table sizes are effectively doubled by custom fields 10,000 posts with 10 cfs each is like having 100,000 rows. Add in revisions and even simple queries become hogs.
So What are/is Pods? Not a plugin … really Pods = Simple, scalable, CMS solution for Wordpress. Ultimate flexibility with being too time intensive.  Frontend/Backend Customization a cinch.
Example: Flight List
Example: Flight List
Example: Flight List
Example: Flight List
Example: Flight List
Example: Flight List
Example: Flight List
Example: Flight List
Example: Templating
Example: Templating <?php $flight = new Pod(‘flight’); $flight->findRecords(‘arrives ASC’, -1); echo $flight->showTemplate(‘flight-list’); ?>
Example: Templating
Example: Templating {@field.column}
Example: Templating {@airline.name} - {@name}, {@departs} <br/>
Example: Templating http://www.yourdomain.com/flights/
Example: Templating http://www.yourdomain.com/flights/?airline=2
Example: Templating <?php $flight = new Pod(‘flight’); $flight->findRecords(‘arrives ASC’, -1); echo $flight->getFilters(‘airline’, ‘Filter’); echo $flight->showTemplate(‘flight-list’); ?>
Example: Templating
Example: Templating <?php $form = new Pod('flight'); echo $form->publicForm(); ?>
Example: Templating
Example: Templating <?php $form = new Pod('flight'); echo $form->publicForm(); ?> <?php $form = new Pod('flight'); $fields = array('name','arrive','depart'); echo $form->publicForm($fields); ?>
Example: Templating
Example: Templating
Showcase
Multiple custom fields? function get_post_meta_multiple($metaDataList) { 	global $wpdb; 	$querystr = "SELECT p.* FROM $wpdb->posts AS p WHERE p.ID IN ( "; 	$querystr .= "SELECT post_id FROM $wpdb->postmeta WHERE "; 	$innerqry = array(); foreach($metaDataList as $key => $value) { 		$innerqry[] = $wpdb->prepare( "(meta_key = %s AND meta_value = %s)", $key, $value );	 	} 	$querystr .= implode(" OR ", $innerqry); 	$querystr .= " GROUP BY post_id "; 	$querystr .= "HAVING count(*) = " . count($metaDataList); 	$querystr .= ") AND p.post_status = 'publish' "; 	$metaResults = $wpdb->get_results($querystr, OBJECT);					 	return $metaResults; } Source: http://tinyurl.com/ldadam
Showcase <?php $di = new Pod('distress_index'); $di->findRecords('name DESC', -1, "t.un > 6.00 AND t.cpi < 2.00"); echo $di->showTemplate('distress_data_table'); ?>
Scalability Using Custom Fields: 600 rows x 6 custom fields = 3600 table rows Using Pods: 600 table rows
Showcase
What about Custom Taxonomies/Post Types?	 Wordpress argues that custom taxonomies and the introduction of post types alleviates the need for excessive use of custom fields.  But this only increases the scalability slightly, there are still problems for large sites.
Pods-nosis Negative?	 Because pods data is saved in separate tables, standard Wordpress post features are not available. (i.e. comments/akismet) Wordpress does not currently endorse the pods cms strategy and instead is pushing the “one post type fits all strategy”. Pods community is considerably smaller than the wordpress community.
Why use pods?	 Learn one plugin, build anything you want. Your site has lots of relationships between types of content. Scalability is a concern.  Truly custom, customization
Summary	 There is no RIGHT way to use Wordpress as a CMS. Pods is a tool for developers, not users.  Pods is the most flexible/scalable CMS option currently available for Wordpress.
More info? www.podscms.org www.mikevanwinkle.com @podscms, @mpvanwinkle
A Question? Should Wordpress.org abandon it’s own attempts to make WP a CMS? Can WP be everything to everyone?

More Related Content

Similar to Wordcamp Fayetteville Pods Presentation (PPTX)

Wordcamp Fayetteville Pods Presentation (PDF)
Wordcamp Fayetteville Pods Presentation (PDF)Wordcamp Fayetteville Pods Presentation (PDF)
Wordcamp Fayetteville Pods Presentation (PDF)mpvanwinkle
 
An Introduction to Windows PowerShell
An Introduction to Windows PowerShellAn Introduction to Windows PowerShell
An Introduction to Windows PowerShellDale Lane
 
Pxb For Yapc2008
Pxb For Yapc2008Pxb For Yapc2008
Pxb For Yapc2008maximgrp
 
Intro to CouchDB
Intro to CouchDBIntro to CouchDB
Intro to CouchDBsbisbee
 
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)James Titcumb
 
Advanced Perl Techniques
Advanced Perl TechniquesAdvanced Perl Techniques
Advanced Perl TechniquesDave Cross
 
Advanced Drupal Views: Theming your View
Advanced Drupal Views: Theming your ViewAdvanced Drupal Views: Theming your View
Advanced Drupal Views: Theming your ViewRyan Cross
 
Modern Web Development with Perl
Modern Web Development with PerlModern Web Development with Perl
Modern Web Development with PerlDave Cross
 
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...webhostingguy
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescriptDavid Furber
 
How Xslate Works
How Xslate WorksHow Xslate Works
How Xslate WorksGoro Fuji
 
Practical catalyst
Practical catalystPractical catalyst
Practical catalystdwm042
 
P H P Part I I, By Kian
P H P  Part  I I,  By  KianP H P  Part  I I,  By  Kian
P H P Part I I, By Kianphelios
 
Allura - an Open Source MongoDB Based Document Oriented SourceForge
Allura - an Open Source MongoDB Based Document Oriented SourceForgeAllura - an Open Source MongoDB Based Document Oriented SourceForge
Allura - an Open Source MongoDB Based Document Oriented SourceForgeRick Copeland
 
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)James Titcumb
 

Similar to Wordcamp Fayetteville Pods Presentation (PPTX) (20)

Wordcamp Fayetteville Pods Presentation (PDF)
Wordcamp Fayetteville Pods Presentation (PDF)Wordcamp Fayetteville Pods Presentation (PDF)
Wordcamp Fayetteville Pods Presentation (PDF)
 
PHP and Cassandra
PHP and CassandraPHP and Cassandra
PHP and Cassandra
 
An Introduction to Windows PowerShell
An Introduction to Windows PowerShellAn Introduction to Windows PowerShell
An Introduction to Windows PowerShell
 
Pxb For Yapc2008
Pxb For Yapc2008Pxb For Yapc2008
Pxb For Yapc2008
 
Intro to CouchDB
Intro to CouchDBIntro to CouchDB
Intro to CouchDB
 
Framework
FrameworkFramework
Framework
 
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)
Kicking off with Zend Expressive and Doctrine ORM (PHP UK 2017)
 
Advanced Perl Techniques
Advanced Perl TechniquesAdvanced Perl Techniques
Advanced Perl Techniques
 
Advanced Drupal Views: Theming your View
Advanced Drupal Views: Theming your ViewAdvanced Drupal Views: Theming your View
Advanced Drupal Views: Theming your View
 
PHP
PHP PHP
PHP
 
Modern Web Development with Perl
Modern Web Development with PerlModern Web Development with Perl
Modern Web Development with Perl
 
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescript
 
How Xslate Works
How Xslate WorksHow Xslate Works
How Xslate Works
 
Practical catalyst
Practical catalystPractical catalyst
Practical catalyst
 
P H P Part I I, By Kian
P H P  Part  I I,  By  KianP H P  Part  I I,  By  Kian
P H P Part I I, By Kian
 
Modern Perl
Modern PerlModern Perl
Modern Perl
 
Ams adapters
Ams adaptersAms adapters
Ams adapters
 
Allura - an Open Source MongoDB Based Document Oriented SourceForge
Allura - an Open Source MongoDB Based Document Oriented SourceForgeAllura - an Open Source MongoDB Based Document Oriented SourceForge
Allura - an Open Source MongoDB Based Document Oriented SourceForge
 
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)
Kicking off with Zend Expressive and Doctrine ORM (Sunshine PHP 2017)
 

Recently uploaded

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 

Recently uploaded (20)

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

Wordcamp Fayetteville Pods Presentation (PPTX)

  • 1. Pods + WP = CMS Sort of …
  • 2. What do we want in a CMS? Flexible – Does different things Robust – Does things well
  • 3. Is Wordpress a CMS? Yes Wordpress is really good at publishing one kind of content: the Post Its interface is easy to learn and easy to teach. Theming is especially powerful. Design community Plugins and custom fields provide additional flexibility on a post by post basis.
  • 4. Is Wordpress a CMS? No Major challenges customizing backend UI All post types essentially the same Custom fields difficult to work with in complex ways Scalability issues
  • 5. So what? Time is money Consultants need to maximize functionality/time equation.
  • 6. Custom Fields Good for on the fly customization Bad for complex content types
  • 7. Querying Custom Fields $args = “meta_key=airline_name&value=American”; $args = “meta_key=arrives&meta_compare=>=&meta_value=DATE()” query_posts($args);
  • 8. Multiple custom fields? function get_post_meta_multiple($metaDataList) { global $wpdb; $querystr = "SELECT p.* FROM $wpdb->posts AS p WHERE p.ID IN ( "; $querystr .= "SELECT post_id FROM $wpdb->postmeta WHERE "; $innerqry = array(); foreach($metaDataList as $key => $value) { $innerqry[] = $wpdb->prepare( "(meta_key = %s AND meta_value = %s)", $key, $value ); } $querystr .= implode(" OR ", $innerqry); $querystr .= " GROUP BY post_id "; $querystr .= "HAVING count(*) = " . count($metaDataList); $querystr .= ") AND p.post_status = 'publish' "; $metaResults = $wpdb->get_results($querystr, OBJECT); return $metaResults; } Source: http://tinyurl.com/ldadam
  • 9. Scalability Most wordpress users will never experience performance issues because the number pages just isn’t enough to matter. But consultants still need to be concerned.
  • 10. Scalability All posts/types are in one table. All custom fields are in longtext format which means they can store up to 4GB. Table sizes are effectively doubled by custom fields 10,000 posts with 10 cfs each is like having 100,000 rows. Add in revisions and even simple queries become hogs.
  • 11. So What are/is Pods? Not a plugin … really Pods = Simple, scalable, CMS solution for Wordpress. Ultimate flexibility with being too time intensive. Frontend/Backend Customization a cinch.
  • 21. Example: Templating <?php $flight = new Pod(‘flight’); $flight->findRecords(‘arrives ASC’, -1); echo $flight->showTemplate(‘flight-list’); ?>
  • 24. Example: Templating {@airline.name} - {@name}, {@departs} <br/>
  • 27. Example: Templating <?php $flight = new Pod(‘flight’); $flight->findRecords(‘arrives ASC’, -1); echo $flight->getFilters(‘airline’, ‘Filter’); echo $flight->showTemplate(‘flight-list’); ?>
  • 29. Example: Templating <?php $form = new Pod('flight'); echo $form->publicForm(); ?>
  • 31. Example: Templating <?php $form = new Pod('flight'); echo $form->publicForm(); ?> <?php $form = new Pod('flight'); $fields = array('name','arrive','depart'); echo $form->publicForm($fields); ?>
  • 35. Multiple custom fields? function get_post_meta_multiple($metaDataList) { global $wpdb; $querystr = "SELECT p.* FROM $wpdb->posts AS p WHERE p.ID IN ( "; $querystr .= "SELECT post_id FROM $wpdb->postmeta WHERE "; $innerqry = array(); foreach($metaDataList as $key => $value) { $innerqry[] = $wpdb->prepare( "(meta_key = %s AND meta_value = %s)", $key, $value ); } $querystr .= implode(" OR ", $innerqry); $querystr .= " GROUP BY post_id "; $querystr .= "HAVING count(*) = " . count($metaDataList); $querystr .= ") AND p.post_status = 'publish' "; $metaResults = $wpdb->get_results($querystr, OBJECT); return $metaResults; } Source: http://tinyurl.com/ldadam
  • 36. Showcase <?php $di = new Pod('distress_index'); $di->findRecords('name DESC', -1, "t.un > 6.00 AND t.cpi < 2.00"); echo $di->showTemplate('distress_data_table'); ?>
  • 37. Scalability Using Custom Fields: 600 rows x 6 custom fields = 3600 table rows Using Pods: 600 table rows
  • 39. What about Custom Taxonomies/Post Types? Wordpress argues that custom taxonomies and the introduction of post types alleviates the need for excessive use of custom fields. But this only increases the scalability slightly, there are still problems for large sites.
  • 40. Pods-nosis Negative? Because pods data is saved in separate tables, standard Wordpress post features are not available. (i.e. comments/akismet) Wordpress does not currently endorse the pods cms strategy and instead is pushing the “one post type fits all strategy”. Pods community is considerably smaller than the wordpress community.
  • 41. Why use pods? Learn one plugin, build anything you want. Your site has lots of relationships between types of content. Scalability is a concern. Truly custom, customization
  • 42. Summary There is no RIGHT way to use Wordpress as a CMS. Pods is a tool for developers, not users. Pods is the most flexible/scalable CMS option currently available for Wordpress.
  • 43. More info? www.podscms.org www.mikevanwinkle.com @podscms, @mpvanwinkle
  • 44. A Question? Should Wordpress.org abandon it’s own attempts to make WP a CMS? Can WP be everything to everyone?