Support » Plugin: HMK Featured Images for Categories and pages. » Icon not showing in latest news widget

  • Hi,

    I’m using a theme with a “latest news widget”.

    I want to show the icons i’ve linked to my categories using this plugin.
    example: http://dev.verzekeringen-portaal.net

    The icon showing in front of my news-item on this widget is programmed in the “Class-framework-widgets.php” file as the following:

    echo $image;

    When I replace this code by the following, I’m not getting an icon as you can see:

    if (function_exists(‘hmk_taxonomy_image_url’)) echo hmk_taxonomy_image_url();

    even though I’ve linked an tiny image (48×48) to each category and my news items are assigned to these categories.

    Any advice?

    Thanks in advance!
    Vanwero.

    https://wordpress.org/plugins/hmk-add-images-for-categories-and-pages/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Muhammad Kashif

    (@xpertone)

    Hey Vanwero,

    Please make sure you are able to get the category ID within that function in Class-framework-widgets.php where you are calling the function.

    Thanks,

    Hi Muhammad,

    Thanks for your quick reply!
    How can I check that? Also with an echo in this code?

    I’m not a programmer. Sorry… if so, can you say how i can test this please?

    Thanks!
    Vanwero

    Plugin Author Muhammad Kashif

    (@xpertone)

    Hey Vanwero,

    can you confirm which theme you are using ?

    Thanks,

    Plugin Author Muhammad Kashif

    (@xpertone)

    Hey Vanwero,

    Looks like the widget can be displayed on any page or post. for category images to display we should be on category page so that we can grab the category id and fetch image against that.

    What I can do is to update the plugin so that we can get the category image by passing category id.

    then you can get category from news post and pass that to the function to grab the category image.

    Ok Muhammad,

    That would be great!

    Thanks in advance already.

    If you let me know when the plugin is updated, I’ll try it!

    Greets,
    Vanwero!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Icon not showing in latest news widget’ is closed to new replies.