Here’s what we want. Tiling, masonry posts that only display posts from certain categories instead of displaying all of them.
First insert your masonry, tiling posts,
Then, examine the shortcode options. You will need to make sure taxonomy=”category” as seen above. Then, you will need to insert your category slug under terms=”your-category-slug.”
If you don’t know the slug of your category, you can find it by going to POSTS / CATEGORIES then clicking edit on your various categories to copy the slug. That is what you will need to insert in the shortcode.
You can also add multiple categories by separating your categories with commas. Example: terms="your-category-slug1,your-category-slug2"
Here is some code you can copy / paste. You can see we are calling a category called “fashion.” You will need to copy / paste the slug from your own category in its place.
[wc_posts author="" author_name="" p="" post__in="" order="DESC" orderby="date" post_status="publish" post_type="post" posts_per_page="10" taxonomy="category" field="slug" terms="fashion" title="yes" meta_all="yes" meta_author="yes" meta_date="yes" meta_comments="yes" thumbnail="yes" content="yes" paging="yes" size="large" filtering="yes" columns="2" gutter_space="10" heading_type="h2" layout="masonry"][/wc_posts]