22
September 15th, 2011 By Ronald Huereca What is the WordPress Loop?

What is the WordPress Loop?

Embed Size (px)

DESCRIPTION

This presentation describes what the WordPress loop is and why LoopBuddy is a great solution for tackling the complexity of the WordPress loop.

Citation preview

Page 1: What is the WordPress Loop?

September 15th, 2011

By Ronald Huereca

W h a t i s t h e Wo r d P r e s s L o o p ?

Page 2: What is the WordPress Loop?

Most of you have seen this screen

Page 3: What is the WordPress Loop?

Most of you HAVE NOT seen this one

Page 4: What is the WordPress Loop?

When you publish a post...

Your post gets saved in a “posts” database table

Your post can have

Post Meta (custom fields)

Taxonomies (Categories, Tags, Post Format)

Attachments (Featured images, galleries)

And lots more!

Page 5: What is the WordPress Loop?

WordPress and your theme automatically turns this...

Page 6: What is the WordPress Loop?

...into a post your users can see on a web site

Page 7: What is the WordPress Loop?

How do you go from this...

Page 8: What is the WordPress Loop?

...to this?

Page 9: What is the WordPress Loop?

With a Query

Page 10: What is the WordPress Loop?

Queries decide...

Which items to display

Under which category

And sorted in a particular order

And any other conditions you can think of

Page 11: What is the WordPress Loop?

An example query...Grab the Post by ID 2338 Grab the post by post_status draft

Grab posts by the Post’s author Sort by Date Published

Page 12: What is the WordPress Loop?

Once you have the results of the Query, you can display them

Page 13: What is the WordPress Loop?

Here is a query result displayed

Page 14: What is the WordPress Loop?

The results from a query are outputted in the form of a Loop

Page 15: What is the WordPress Loop?

This post is one iteration of a WordPress Loop

Page 16: What is the WordPress Loop?

Let’s look what makes up a Loop Item in WordPress...

Page 17: What is the WordPress Loop?

The Loop DissectedDate Published Post Author

Post Title

Post Content

Page 18: What is the WordPress Loop?

So how do you create your own Loop (cough, the hard way)?

Create your own Query - http://codex.wordpress.org/

Template_Tags/get_posts

Create a page template in your theme - http://

codex.wordpress.org/Pages#Page_Templates

Assign that page template to a page in WordPress

Anything more complicated, you may want to create your own

child theme

Page 19: What is the WordPress Loop?

Or you can use LoopBuddy and Builder (the easy way)

Create unlimited queries and Loop layouts

Override any section

The front page

The archive pages

An individual post or page

Search results

Create a new section

A “blog” archive

A custom 404 page

A sitemap

Page 20: What is the WordPress Loop?

No Coding or Theme modifications Required

Page 21: What is the WordPress Loop?

With LoopBuddy, you control the Loop

Page 22: What is the WordPress Loop?

Try Out LoopBuddy and Be Blown Away at the Possibilities

Try it at: http://trials.ithemes.com/config/loopbuddy

Buy it at: http://pluginbuddy.com/purchase/loopbuddy