WordPress CMS modifications
Making WordPress the ultimate CMS!

WordPress Loop

‘The Loop’ is the name given to the main small piece of code that displays content in a Website or Blog based on WordPress installation. If you have used PHP before this will look familiar, if not don’t panic – just remember it’s called ‘The Loop’ by everyone that uses WordPress.

This code has to be in your template to show posts, pages and content like category listings.

Looking at existing templates is a good start – manipulating The Loop is the key to customising the display of content. It is amazing what you can do and remember you can have multiple loops on one page! Getting control of customised loops is the functionality you need to harness to use WordPress as a CMS.

This will enable you have unlimited display control over your content in your website design – so you can get away from the ‘blog’ structure and produce a full content managed website.

WordPress 3.0 and beyond

WordPress 3.0 has a new, much more efficient way of working with the loop (or other parts of your template file structure) – See the WordPress Codex reference on get_template_part for more information. Don’t worry – all your existing template code will work but WordPress 3.0 has a few new tricks for template designers to use. And remember to backup your files just in case (webhosting packages can do that job for you).

WordPress official sites

WordPress Codex – ‘The Loop’ introduction

WordPress Codex – The default Loop

WordPress Codex – Other Loop tricks

WordPress cheetsheets

The Loop with it’s template tags by Bueltge.de

List of often used template tags / PHP commands used in templates by WP Candy

More Advanced WordPress loop information

Global Variables and the WordPress Loop

Define Your Own WordPress Loop Using WP_Query

Comments are closed.