Shortcodes are a really useful tool to perform functionailty or grab data that you require in your post without the need for complex code knowledge. Using predefined snippets you can pull in the required data you need. We have developed this shortcode for ourselves specificaly for pulling in posts, if you feel this would benefit your wordpress platform then let us know and we can install for you.
Using this show posts shortcode could not be simplier, the shortcode will just list out posts from a certain category, with this you can configure the amount of posts, the order of the posts. The snippt below is the shortcode you would just paste into your post, and below that is the shortcode results working.
Shortcode:
Category – The id of the category you want to display, this defaults to showing all.
Num – The amount of posts you want to show, defaults to 5, -1 will show all.
Order by – Defaults to date.
Order – Either asc for ascending or desc for descending, defaults to asc.
Shortcode in action:
- Google Maps & Geolocation Detection
- Javascript Prototype - Example and code
- Javascript Form Validation Object
- Javascript Calculator
- Custom post categories/category
- Make my site a Responsive website.
- Javascript For Loops - Whats the fastest?
- Chrome reorders keys - not reordering correctly
- Ajax connections manager
- Shortcodes Plugin
- Cookie Law Solution
- Creating a jQuery plugin
- Website Security
- Wordpress functions on non wordpress pages
- Wordpress Basic's
- Get Directory for Image Paths
- Wordpress Widgets not saving
- Show posts short code
- Wordpress 3.3
- HTML Canvas tag
- Why use wordpress?
- Search Engine Optimisation
- What is HTML5?
- Choosing a website
- Web Term Glossary
- What is the difference between CSS and HTML?
This could be very good for our site actually, could you not have it use the category name instead of ID as I think that would be easier?
Hi Lee, I was thinking of using name but as names are not necessarily unique I thought I’d stick with the ID as I know that would always be unique. It’s just more reliable this way.