New Front EN › Support Forums › Kanso Theme Support › Shortcode DISPLAY_POSTS issue
Tagged: kanso, Shortcodes
- This topic has 5 replies, 2 voices, and was last updated 9 years, 5 months ago by
satori.
-
AuthorPosts
-
June 4, 2014 at 2:07 am #3420
ojones
ParticipantHi Andrii,
I have set up my portfolio on the home page of my website and Iam trying to push project types to separate pages using the DISPLAY_POST shortcode, this functionality works fine if I create a blog post and link it, for example: [display_posts category=”5″ order=”DESC” orderby=”date” post_type=”post”] works fine.
But when I try and do it for a portfolio item, for example: [display_posts category=”4″ order=”DESC” orderby=”date” post_type=”project”] nothing shows up on the page.
Any help would be appreciated.
Thankyou,
Ojones
June 6, 2014 at 4:12 pm #3433satori
KeymasterHey Ojones,
first of all, thank you for the purchase!
The reason why the shortcode did not filter the projects is because it did not have such a capability – the “category” parameter refers strictly to the “category” taxonomy, which only relates to classic posts. Once you’ve mentioned this, I thought it might be a good addition to the shortcode, so I’ve introduced filtering by type as well; I will include the feature into the next theme update (version 1.6), and before it’s out you can download this archive, unzip it, and upload the resulting files into the following folder inside your WP install:
/wp-content/plugins/shortcodes/lib/
replacing the existing files. After that, you should be able to use “type=XX” parameter in the shortcode, where XX is the ID of the needed type. Please let me know if it works for you!Sincerely,
Andrii / Satori StudioJune 22, 2014 at 10:42 pm #3570ojones
ParticipantHi Andrii,
Thanks for your help, that works perfectly. I noticed the change was made to the shortcode. Will I need to make sure I don’t update it from now on to not override it?
Thanks again
June 23, 2014 at 1:35 pm #3582satori
KeymasterHey Ojones,
glad it works!
I will include the code into the next version update of Kanso (1.6), and into all future updates from then on, thus you do not need to update the code separately.Sincerely,
Andrii / Satori StudioJune 24, 2014 at 2:39 am #3590ojones
ParticipantGreat, So i just hold off updating the Shortcodes-ultimate plugin until kanso 1.6 comes out?
Thankyou
-
This reply was modified 9 years, 5 months ago by
ojones.
June 24, 2014 at 6:30 am #3593satori
KeymasterHey Ojones,
you can apply the code I’ve posted here to the current version of Kanso as well ;) the 1.6 update will not influence it afterwards.
Sincerely,
Andrii / Satori Studio -
This reply was modified 9 years, 5 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.