• Hi all,

    I’ve been looking to add the date of creation of a post inside “WP-carousel” plugin for days now and I haven’t figured out a solution yet. Hopefully you guys will be able to help.

    I explain myself better:

    I have implemented “wp-carousel” plugin on the homepage of a website.
    Each panel of the carousel has an image and a title. The carousel is populated when a post is added to the “News” category.

    All I want to do is to add the date of creation of each post under the title.
    I have been playing around with the code with no luck.
    I have then decided to add a custom field and enter the date manually but even then I can’t manage to make the custom field show inside the carousel plugin, below is the code I have come up with.

    This is the title and shows up fine:

    <div class=”title-slider”>” title=”<?php echo $item[‘TITLE’]; ?>”><?php echo $item[‘TITLE’]; ?></div>

    This is the code to retrieve the custom field but it won’t work:

    <div class=”postmetadata”><p class=”date”><?php echo get_post_meta($item->ID, ‘dateNews’, true); ?></p></div>

    Any idea how to solve this problem with or without custom field? Many thanks in advance.

    PS: As you can probably see I’m not very good at PHP but I’m doing my best to learn and sorry for bad grammar.

    Regards,
    Jeff

  • The topic ‘How to show the date of posting into WP-carousel’ is closed to new replies.