Support

Home Forums Event Espresso Premium EVT_modified values

EVT_modified values

Posted: July 19, 2021 at 8:32 am


ICLE

July 19, 2021 at 8:32 am

How may I view the detail in the EVT_modified field from the database?


Tony

  • Support Staff

July 19, 2021 at 8:58 am

Hi ICLE,

EVT_modified is mapped to the post_modified field within wp_posts

Is that what you are looking for?

Or do you have an EE_Event object and you want to get the value from that? If so use something like $event->modified();.


ICLE

July 19, 2021 at 9:03 am

What would I do in the event-editor to show this value per event?


Tony

  • Support Staff

July 19, 2021 at 9:35 am

We currently don’t have the option to show the ‘Post modified’ value on the event editor, you’d need some custom code for this.

Where exactly in the event editor are you looking to add that value?


ICLE

July 19, 2021 at 9:39 am

As a last item. I was hoping to add a shortcode in the editor. Perhaps a plugin? Ive done a few of those. How would I code a plugin where all I want to do is display the EVT_modified value somewhere on the page?


Tony

  • Support Staff

July 19, 2021 at 9:54 am

A last item?

Are you wanting to out the EVT_modified value on the event editor itself or output the value on the front end output for the event?


ICLE

July 19, 2021 at 9:56 am

Yes, I am doing some troubleshooting in a localhost but might just display it off page or as white text.


Tony

  • Support Staff

July 19, 2021 at 10:47 am

My apologies but I don’t follow.

I asked if you wanted to display the value on the event editor itself or the front end output and your answer is yes, ok but to which one?

If you are troubleshooting locally and just want to include it on the front end you could just include the_modified_date() within your single.php template file.

Or you could just hook into one of the hooks within EE to do it, like so:


add_action('AHEE_event_details_after_the_content', 'tw_ee_output_evt_modified');
function tw_ee_output_evt_modified(){
    echo 'Modified: '. the_modified_date();
}

Is that what you are looking for?

The support post ‘EVT_modified values’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso