Shortcode excluding options
-
Hi there, I created a page with an index of my posts by using the display-posts shortcode. I’m using a lot of category’s on my blog and there are only two category’s which I do not want to display in my index. Is it possible to create an ‘exclude’ shortcode or do I have to mention all the other category’s in my shortcode and just leave out the two I don’t want to display?
Another question: my shortcode is becoming very long. Are there restictions in the lenght. Is it also possible to create several shortcodes on one page or is it necessary to put them all in one shortcode, like I did.My blog is: femmiefood.wordpress.com
The blog I need help with is: (visible only to logged in users)
-
Hi,
I don’t know of an “exclude categories” argument, but it’s a good idea. You might wish to submit it to the Ideas forum.Another question: my shortcode is becoming very long. Are there restictions in the lenght.
The limit is 100 posts per display posts shortcode.
Is it also possible to create several shortcodes on one page or is it necessary to put them all in one shortcode, like I did.
It is possible to use multiple shortcodes in one page. For example, you could break the categories up as follows:
- Categories beginning with A-I in first shortcode
- Categories beginning with J-R in the second shortcode
Categories beginning with S-Z in the third shortcode.
- The topic ‘Shortcode excluding options’ is closed to new replies.