bigspring / monolith

A starter theme for WordPress built with Twitter Bootstrap
MIT License
9 stars 1 forks source link

Build shortcode to display any post type in any layout #390

Open juliotaylor opened 8 years ago

juliotaylor commented 8 years ago

A shortcode that can render any post type, in any layout, in any order, for example:

'[build post-type="products" layout="snippets" orderby="date" order="asc"]'

juliotaylor commented 8 years ago

@jrgmartin for review / further detail.

Could we refactor all shortcodes into one single one to do this?

harrybigspring commented 8 years ago

Could this also include case studies, testimonials and single versions?

'[build post-type="testimonial" layout="blockquote" id="23"]'

'[build post-type="testimonial" layout="blockquote" category="dogs" orderby="date" order="asc"]'

juliotaylor commented 8 years ago

well, the problem with category is that it's a dynamic taxonomy, which could change from project to project.

It would need a 'taxonomy' variable too.

@jrgmartin

jrgmartin commented 8 years ago

Yes, this is totally do-able and relatively easy to implement.

For taxonomy, we would actually need two vars:

  1. Taxonomy
  2. Term
juliotaylor commented 8 years ago

Can you build this into the spec for the new builder tools in M3?