Livefyre Profile

Activity Stream

@wpbeginner@mriulian Thank you for this link. I followed your instructions to add the feature image. It works but it appears on top of my excerpt and there's no way I can move it within the text. I use the class of img.wp-post-image and apply a float property and a margin but the text does not float around the image in the excerpt.

Should I replace php the_excerpt() with a different php code to make it work? Can you help with that? http://irimina.com

2 years, 8 months ago on WordPress Custom Fields 101: Tips, Tricks, and Hacks

Reply

great post
Can you explain in detail how I can use a custom field for inserting an image in the excerpt. the front page of my site has some excerpts to my posts and i need to add an image from the post to the excerpt, preferably without a plugin.
thank you

2 years, 9 months ago on WordPress Custom Fields 101: Tips, Tricks, and Hacks

Reply

Just trying to be more clear, this is my code:

// in the function page

if (function_exists('register_nav_menus')) { register_nav_menus( array( 'mainNav' ) ); }

// in the header page

<header id="mainHeader">

<nav>

<?php wp_nav_menu(array('menu' => 'main_nav_menu')); ?>

</nav>

</header>

// in the css file

.current{ background-color: #0188AA; color: #fff; text-decoration: none; }

How do I apply this class to my navigation? ( very easy in a static html page but apparently pretty complicated in wordpress).

Thanks in advance

3 years, 1 month ago on How to Style WordPress Navigation Menus

Reply

This is what I did but it doesn t work. I registered my menu in the
functions page and then I called it from the header page as my main
navigation. Now, I have a . current class in my stylesheet to be applied
to the current page but it is not obvious how to do that.
Can you help with a suggestion?

3 years, 1 month ago on How to Style WordPress Navigation Menus

Reply

Thank you for mentioning about the css classes in the screen options panel. The problem that I have with my navigation is how to style the nav menu so that each menu item gets a specific background color when you arrive at a certain page. You mention creating a class such as .current_page_item{} in your style sheet. But how to apply this class in the header.php?

3 years, 1 month ago on How to Style WordPress Navigation Menus

Reply