- This topic has 1 reply, 1 voice, and was last updated 7 years, 11 months ago by .
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.
These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.
Been working a bit on a new theme locally for a project of mine. So far I´ve managed to complete most things. But I´ve encountered a weird error?
do_action( 'genesis_entry_header' ); Do display a header with a link to the post in a widget. But all I get is a title output with the post title as if I were on a single post?
Here is the code in it´s full glory
<div class="blog-list"> <?php while( $flexible_posts->have_posts() ) : $flexible_posts->the_post(); global $post; ?> <?php printf( '<article %s>', genesis_attr( 'entry' ) ); echo '<div class="post-image"><a href="' . get_permalink() . '">' . genesis_get_image( array( 'size' => 'related' ) ). '</a></div>'; do_action( 'genesis_entry_header' ); echo '</article>'; ?> <?php endwhile; ?> </div><!-- .blog-list -->
It´s the same as found in the loop structure in the base genesis. I´ve used this code before and it works just fine. Outputting a clickable title whenever I´ve used it.
So I´m a bit worried about this now.
Sadly no live version available yet 🙁 I´ve used basically the same code on my current site http://henrikblomgren.net for the blog area on the front page. There it outputs the right things. Any idea as to why it doesn´t output the link as it should on my local development site? It just stopped working for some odd reason.
Well... I turned my computer off. Went away for a bit, changed from having a static home page and a certain page for articles to being dynamic, refreshed the site and voila, links work as they should again.
So... am I some computer wizard finding new ways of breaking everything or just what am I?
A quick test, once again using the prefered way of handling a front page and blog page without using the blog template results in the above error. So fun times ahead.
© 2023 WPEngine, Inc.