[email protected]
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageI posted this on CSS-Tricks.com and someone said to use this:
<div class="fourcolumn"> <h2>Latest Post</h2> <?php query_posts( 'posts_per_page=1' ); ?> <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <div class="lp-dates"><?php the_time('M <br /> j') ?></div> <div class="latest-post"><a href="<?php the_permalink(); ?>"><?php wpe_excerpt('wpe_excerptlength_teaser', 'wpe_excerptmore'); ?></a><div class="dash-divider"></div></div> <?php endwhile; ?> <?php else: ?> <h1>Not Found</h1> <p>Apologies, but no results were found for the requested archive. Perhaps searching will help find a related post</p> <?php endif; ?> </div>
It works perfect!
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageI tried this and it just brings back errors:
<?php if (have_posts()) : ?> <?php // The Query $query = new WP_Query( 'posts_per_page=5' ); // The Loop while ( $the_query->have_posts() ) : $the_query->the_post(); echo '<li>'; the_title(); echo '</li>'; endwhile; // Reset Post Data wp_reset_postdata(); ?> <?php endif; ?>
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageI’ve never heard of post_status => publish. I’m not very good at php. So obviously this is over my head.
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageNo, I want to show the 5 most recent out of all of the posts. I know you can display the most recent post titles with a widget. However, I want a description under each one.
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageHaha, okay. That is what I have been saying all along. So you cannot pull all of your posts on any other page but the home because the is no way to target them. Nice.
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every Page<?php if ( ! have_posts() ) : ?> <?php // The Query $query = new WP_Query( 'pagename=blog' ); // The Loop while ( $the_query->have_posts() ) : $the_query->the_post(); echo '<li>'; the_title(); echo '</li>'; endwhile; // Reset Post Data wp_reset_postdata(); ?>
I’m guessing this is completely wrong
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageNever mind I see that there is “pagename”.
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageThe post from the blog, or index page. Can you not pull posts from a page?
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageSo to call the blog feed I would put this in functions:
<?php // The Query $query = new WP_Query( 'name=blog' ); // The Loop while ( $the_query->have_posts() ) : $the_query->the_post(); echo '<li>'; the_title(); echo '</li>'; endwhile; // Reset Post Data wp_reset_postdata(); ?>
I guess there is no way to use index.html. Also, how do I call this in the feed? I will keep reading. Sorry, I’m a little slow :/.
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageSorry, what else can you select?
Forum: Fixing WordPress
In reply to: How to put Blog Loop on Every PageThanks, I have read through multiple_loops before. I know it talks about calling the categories. How do you call the blog feed from the index? This seems like it should be something simple :/.
Forum: Fixing WordPress
In reply to: Cannot modify header information error w/in DashboardFixed it!! Thank you!! <3