|
JDWordpress
v.2014-02-11
Wordpress Plugin for CakePHP
|
Part of plugin JDWordpress
More...
Data Structures | |
| class | JDBlogPostDataComponent |
| This class implements a component for including Wordpress data in other controllers' view variables. More... | |
Part of plugin JDWordpress
This component provides functions to add to your AppController or other controller in order to populate your views for including JDWordpress content in other areas of your application. to other areas of your site.
Alternatives are to use requestAction (see the actions available in JDBlogPost.php) which has some inherent issues, or to use the helpers in JDBlogPostHelper (which uses this Component to do the heavy lifting).
Note that this component does break MVC by communicating directly with the database, but it's a black box to you and allows you to avoid breaking the paradigm yourself. This is the most Cake-like way to include the Wordpress data in your own controllers' views.
getOneRandomPost()getSitemapBody()tocArticlesWithDateHeaders( $slug = {all} )tocForTaxonomyType( $type = {category} )tocRSSForTaxonomyType( $type = {category} )tocRecent( $slug = {all} )tocTaxonomyArticles( $type = {category} )