Forum Replies Created
-
AuthorPosts
-
brettatkinMember
Jackie,
It still isn't working for me on the second two example sites. On the first site, the "Blog" link isn't highlighted when looking at single post pages and on the second site, the "Recent News" link is isn't highlighted when look at single post pages.
What browser are you using? When you view the source, are you seeing any of the typical “current-menu-item” classes getting added to the navigation?
Thanks
Brett
brettatkinMemberOkay, I think I got it. Priority determines the loading order of functions within that hook.
add_action( ‘genesis_before_header’, ‘genesis_after_entry_widget_area’, 5 );
Even though the above is possible, that seems like lazy coding isn't it - loading something in the header that was intended to be after the post?
Thanks
brettatkinMemberI'm don't want to move it, I'm just curious. Shouldn't anything tied to the "genesis_after_entry" always be after the entry?
I'm looking at this and wondering how moving it does anything. Isn't is always going to be after the genesis_entry_footer and before the genesis_after_endwhile?
http://genesistutorials.com/visual-hook-guide/
The SP documentation says "This hook executes after each entry in all loop blocks".
So, in the code example, where was the widget going to get displayed before the change and where is it getting displayed now?
Is there any guide or documentation that explains the load priority? From what I've read, it is all relative and you have to use a bit of trial and error to reposition things. I've only used priority to reposition my theme stylesheet to come after various plugin stylesheets and I just kept picking an higher number (I believe 10 is the default) until it was at the end.
Thanks for responding.
brettatkinMemberI had the same issue and got this working on Enterprise Pro. Thanks tomatillodesign and Tonya. What I don't understand is why it doesn't work by default. Does the framework exclude CPT's by default?
Thanks
brettatkinMemberThank you, I got it working. I'm sure I'll have some more questions, but this got things moving in the right direction.
Here is the code I'm using. I followed the same process for the archive page.
<?php //* Remove the entry meta in the entry header (requires HTML5 theme support) remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); //* Remove the entry meta in the entry footer (requires HTML5 theme support) remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); //* Display custom fields above entry content add_action( 'genesis_entry_content', 'sr_post_content', 9 ); function sr_post_content() { echo '<div class="one-third first">'; echo '<h2>Date & Time:</h2>'; $date = DateTime::createFromFormat('Ymd', get_field('conference_date')); echo '<p>'; echo $date->format('m/d/Y').'<br />'; echo the_field('conference_time'); echo '</p>'; echo '</div>'; echo '<div class="one-third">'; echo '<h2>Location:</h2>'; echo '<p>'; echo the_field('conference_location'). '<br />'; echo the_field('conference_address') . '<br />'; echo the_field('conference_city') . ', ' . get_field('conference_state') . ' ' . get_field('conference_zip_code'); echo '</p>'; echo '</div>'; echo '<div class="one-third">'; echo '<h2>Host:</h2>'; echo '<p>'; echo the_field('host_name') . '<br />'; echo the_field('host_school'); echo '</p>'; echo '</div>'; echo '<div style="clear:both;"></div>'; } genesis(); ?>
brettatkinMemberI see that. I did remove the "All in One SEO" plugin. The two sections in question are CPT's, so I wonder if there is an issue with the plugin and/or conflict with the framework.
Thanks
brettatkinMemberI used the function recommendation.
The framework explanation is a great link!
Thank you Kelly
brettatkinMemberThank you David, this is exactly what I needed.
June 23, 2014 at 11:35 am in reply to: Active State for Blog Menu Item for Individual Blog Posts #111183brettatkinMemberThanks, this worked with one modification. I had to add the following to the if statement because the Blog link was active on the home page.
!is_home()
Shouldn't this be happening automatically though?
brettatkinMemberI was finally able to find an answer - I wasn't really asking the question correctly. I found this post on Stack Exchange.
Which leads to this post:
http://theme.fm/2011/09/wordpress-internals-how-wordpress-boots-up-part-2-2437/
For item 24, he says WP autoloads the primary and child theme's functions.php file. This is what I was missing. WP triggers the loading of the functions.php file which enables everything else to work.
Thanks for sticking with me on this.
brettatkinMemberThanks nunotmp, that's exactly what I wanted. I used the following to remove the styling block as well.
remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_open', 5 );
remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_close', 15 );
remove_action( 'genesis_entry_header', 'genesis_do_post_title' );This works, but is it correct/complete way to do this?
brettatkinMemberI understand that, but how/where is that file called in the theme's index.php?
brettatkinMemberYes, but how does the index.php know where to look to find that? The only code on the index.php page is:
genesis();
Thanks
brettatkinMemberI want to remove the title. I want to manage everything within the editor. I'm going to insert image, h1 and then content.
I'm hoping the method for doing something like this will be similar across all Genesis themes.
Thanks!
brettatkinMemberI got it. I had entered a "Content Character Limit", not sure why... When you do that, it strips any formatting coming from the selected featured page. It also enables the "More Text" to display a button that links to the featured page.
My Title and Button are part of the page content so that I can link to something other than the featured page.
Thanks for suggesting I play around with the settings more. Now that I think about it, it makes sense.
brettatkinMemberSorry, the current site isn't live...
I created a beta site for you to see.
Nothing beyond the home page works because I haven't done a search/replace on the db.
brettatkinMemberWorks perfectly, thanks!
Brett
-
AuthorPosts