I’ve been digging through the documentation and forum but I can’t find anything explaining how to use php to display a mashup query in a template. Besides using the combination of php and shortcodes.
The goal is to dynamically generate a mashup map of dealerships (custom post type) by state (category).
Example: If I want to show all dealerships in Florida, this combination of php and shortcode, added to a template works perfectly.
echo do_shortcode
('
[mashup query=
"dealership_state=florida&
posts_per_page=-1"
]
');
Is there a way to show Arizona, California, or another state without creating indivual static pages?
Assuming I’ve found the current state (category) with something like:
$current_dealership_state=
strip_tags(
get_the_term_list(
$post->ID, 'dealership_state'
)
);
Is there a way to php code this into a template replacing florida with $current_dealership_state
?