GeoDirectory SupportDisplay Featured Image on Detail Sidebar – GeoDirectory Support https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/feed Sat, 04 Apr 2026 06:20:01 +0000 http://bbpress.org/?v=2.5.14-6684 en-US https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-27931 <![CDATA[Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-27931 Mon, 19 Jan 2015 08:35:38 +0000 insomniacuva Hello,
Can you please help me display the Listing’s featured image on the Detailed Page Sidebar?

Should be fairly easy but I’m having a lot of trouble.

I’ve tried messing around with geodirectory_hooks_actions.php but not really getting anywhere.

Please see attached image for conceptual sample.

Thanks!

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-28088 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-28088 Mon, 19 Jan 2015 22:39:31 +0000 Paolo Hi,

the hook to do that is documented here (one of the few so far…)

http://docs.wpgeodirectory.com/geodir_social_sharing_buttons_html/

The edit to the code to output the featured image is minimal.

The code below if added to your theme functions.php will result in the image attached.


/**
 * Wraps the sharing buttons div in our custom container
 *
 * @param string $content_html The HTML of the sharing buttons div
 * @return string Filtered HTML.
 */
function my_theme_geodir_social_sharing_buttons_html( $content_html ) {
	global $post; 
	$thumb = the_post_thumbnail( 'medium' );

   return "<div class='my-theme-class'>".$thumb."</div>".$content_html;

}
add_filter( 'geodir_social_sharing_buttons_html', 'my_theme_geodir_social_sharing_buttons_html', 10, 1 );

Now you just need to style css according to your needs.

Thx

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54207 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54207 Wed, 23 Sep 2015 14:13:09 +0000 Brigitte Hello paolo,

Thank you for this function, it works well, and the featured image is displayed on the sidebar.

But the function has a small problem. I want to disable sharing on social networks.

If I disable the option (Design => Detail settings => Disable Tweet, Fb Like, Google+ buttons section that displays on Detail page sidebar), the featured image disappears. It reappears if I re-activate the option.

Is this a bug?

Thanks in advance.

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54218 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54218 Wed, 23 Sep 2015 15:39:34 +0000 Paolo Hi,

no that is not a bug, that function hooks into the social sharing html (geodir_social_sharing_buttons_html). If you remove the social sharing you remove everything hooked into it’s html.

You’ll need to use a different hook, depending on what you have hidden on that sidebar.

You could try geodir_post_sidebar_html, however that could mess up the sidebar style if you don’t do it correctly.

Let us know how you went.

Thanks

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54355 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-54355 Thu, 24 Sep 2015 12:35:54 +0000 Brigitte Hello paolo,

Sorry, I admit that this is a silly question … It’s totally logical!
Thanks for reply, I will try with another hook.

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-65492 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-65492 Mon, 28 Dec 2015 11:21:36 +0000 Tony paolo this is perfect! Now can we just hide the feature image from the gallery not that it’s in the sidebar? Just want to say like if image is feature don’t show in gallery.

]]>
https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-65544 <![CDATA[Reply To: Display Featured Image on Detail Sidebar]]> https://wpgeodirectory.com/support/topic/display-featured-image-on-detail-sidebar/#post-65544 Mon, 28 Dec 2015 17:49:20 +0000 Paolo Hi,

that is not possible, I’m sorry.

Thanks

]]>