admin管理员组文章数量:1122846
I have a landing page that follows the same UI but depending on the URL path, it will render different content. for example the base URL is sitename/lp/top10/. following that it will either be A or B which is supposed to point to two different categories and then under either A or B there are a list of category names.
Custom post types have been registered as A or B and field groups have been created on the dashboard and I've create posts as examples. I then create a taxonomy in ACF as a_category and b_category and assigned it to A or B in custom posts. in the code i set up a default redirect when a user clicks on sitename it redirects to sitename/lp/top10/[A] but when i add a category name to that it will render the same posts as sitename/lp/top10/[A].
My question is how can i get the url path slug to provide a list of all the posts that pertain to the given category name at the end of the url. i've only gotten so far is to sitename/lp/top10/[A or B]. Essentially can someone guide me on how I can group contents into two buckets that each have sub-categories that contain posts that are assigned to categories with A or B accordingly?
Also since this is just a landing page i have everything content-wise in my index.php where it dynamically renders sitename/lp/top10/[A or B] and my settings>permalinks is set to plain because anytime i change it to custom it breaks. otherwise i have my header in header.php and footer.php but since this was a landing page that was static i didn't think to create single-{name}.php and archive-{name}.php.
thanks!
本文标签: permalinkstaxonomies ACF Wordpress
版权声明:本文标题:permalinks - taxonomies ACF Wordpress 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736308617a1933725.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论