{"id":43276,"date":"2016-04-19T06:45:01","date_gmt":"2016-04-19T06:45:01","guid":{"rendered":"https:\/\/wordpress.org\/plugins-wp\/logic-shortcodes\/"},"modified":"2016-04-28T19:12:59","modified_gmt":"2016-04-28T19:12:59","slug":"logic-shortcodes","status":"publish","type":"plugin","link":"https:\/\/eo.wordpress.org\/plugins\/logic-shortcodes\/","author":13973526,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_crdt_document":"","version":"1.0","stable_tag":"trunk","tested":"5.4.19","requires":"2.5.0","requires_php":"","requires_plugins":"","header_name":"Logic Shortcodes","header_author":"Samuel Diethelm","header_description":"","assets_banners_color":"","last_updated":"2016-04-28 19:12:59","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/wordpress.org\/plugins\/logic-shortcodes\/","header_author_uri":"http:\/\/www.samueldiethelm.com\/","rating":0,"author_block_rating":0,"active_installs":10,"downloads":1501,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":[],"upgrade_notice":[],"ratings":{"1":0,"2":0,"3":0,"4":0,"5":0},"assets_icons":[],"assets_banners":[],"assets_blueprints":{},"all_blocks":[],"tagged_versions":[],"block_files":[],"assets_screenshots":[],"screenshots":[],"jetpack_post_was_ever_published":false},"plugin_section":[],"plugin_tags":[4060,25157,4672,91,5058],"plugin_category":[57],"plugin_contributors":[96310],"plugin_business_model":[],"class_list":["post-43276","plugin","type-plugin","status-publish","hentry","plugin_tags-conditional","plugin_tags-logic","plugin_tags-postmeta","plugin_tags-taxonomy","plugin_tags-term","plugin_category-taxonomy","plugin_contributors-samueldiethelm","plugin_committers-samueldiethelm"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/s.w.org\/plugins\/geopattern-icon\/logic-shortcodes.svg","icon_2x":false,"generated":true},"screenshots":[],"raw_content":"<!--section=description-->\n<p>This plugin enables the use of [if] shortcodes to work with conditional logic based on the existence of post meta or taxonomy terms on posts and pages.<\/p>\n\n<p>Please consider taking a minute to rate the plugin or let me know any feature request. Thanks!<\/p>\n\n<h4>Taxonomy<\/h4>\n\n<p>With conditional logic for taxonomy terms, you can use names, slugs or term_ids:<\/p>\n\n<ul>\n<li>[if taxonomy=\"category\" slug=\"cars\"]Content to show[\/if]<\/li>\n<li>[if taxonomy=\"category\" name=\"Cars\"]Content to show[\/if]<\/li>\n<li>[if taxonomy=\"category\" id=\"123\"]Content to show[\/if]<\/li>\n<\/ul>\n\n<h4>Post Meta<\/h4>\n\n<p>Post meta (or custom field) logic can be used to check if a certain meta_key AND meta_value combination are present or just a meta_key:<\/p>\n\n<ul>\n<li>[if postmeta=\"car_model\"]Content to show if car model info is present[\/if]<\/li>\n<li>[if postmeta=\"car_model\" value=\"Tesla Model S\"]Content to show if car model is Tesla Model S[\/if]<\/li>\n<\/ul>\n\n<!--section=installation-->\n<ol>\n<li>Upload the plugin files to the <code>\/wp-content\/plugins\/<\/code> directory, or install the plugin through the WordPress plugins screen directly.<\/li>\n<li>Activate the plugin through the 'Plugins' screen in WordPress<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt>Where can I use the logic?<\/dt>\n<dd><p>Anywhere where shortcodes are accepted and a post or page is being displayed.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.0<\/h4>\n\n<ul>\n<li>Initial upload<\/li>\n<\/ul>","raw_excerpt":"Use shortcodes for conditional logic based on post meta or taxonomy terms.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/43276","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=43276"}],"author":[{"embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/samueldiethelm"}],"wp:attachment":[{"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=43276"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=43276"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=43276"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=43276"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=43276"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/eo.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=43276"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}