Can someone produce an important Wordpress Loop and show me what is happening by using it? Let me come up with some templates, however i avoid well with blackboxing. Quite simply, I am fully able to writing my very own Content management systems, however when it involves using another person's and it is arbitrary rules, I am completely baffled, and that i cannot get my mind round the standard loop Wordpress uses. Interesting patient guidance.
You might like to begin with reading through the codex article around the The_Loop. Beyond looking at their loop documentation, reading through on the different template tags ought to be useful for you too.
Starts the loop:
<?php if ( $posts ) : foreach ( $posts as $post ) : start_wp(); ?>
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
Shows the publish title like a permalink towards the publish.
<h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2
<small><?php the_time('F jS, Y') ?> by <?php the_author_posts_link() ?></small>
Pulls the entire contents from the publish, covered with a div container to help ease CSS styling.
Shuts the loop, and shows a note if no posts put together.
<?php endforeach; else: ?> <p><?php _e('Sorry, no posts matched your criteria.'); ?></p> <?php endif; ?>
There's a very nice tutorial from SpoonGraphics explaining building your personal theme for wordpress and explaining the needed coding. Additionally, it covers the conventional wordpress loop and describes building around it: