How to alter the date in the circle?

Open21298LowContent Timeline Drupal
Profile Reply
zumbasan Client

Hello Shindiri team,

I was wondering if it was possible to change the post date information that appears in the circle on each item from the day and month it was posted, to just the year it was posted.

Our timeline is being used to display only one or two items per year, so the day and month information is not important.

Any help would be greatly appreciated.



User Description Posted On
zumbasan Client

If anyone else is looking for a solution to this, I found the code you need to alter in content_timeline.module lines 262 - 264
I got the desired effect by changing those lines to this:

$node_crated_day = gmdate("Y", $vars['row']->node_created);
    /*$node_crated_month = strtoupper (gmdate("M", $vars['row']->node_created));*/ 
    $vars['show_date'] = '<div class="post_date">'.$node_crated_day.'</span></div>';
This alters the first variable to bring back the year the item was posted, and rewrites the show date variable to only include the first variable.