Code Available in the Nucleus Forum at http://forum.nucleuscms.org/viewtopic.php?t=2811 (Author: TrenT)
This plugin can be used to calculate how much time has gone by since an event in the plugin parameters. If item is in the past, it will show “ago” at the end of the string. There is a format option to place HTML tags or CSS tags in the plugin options. This plugin is similar to another one I wrote in NP_Countdown, but has the option for displaying years, months, weeks and days versus just days in that plugin.
Usage is: <%HowMuchTime(detail,year,month,day,event)%>. If item is in the past, it will show “ago” at the end of the string. Sample usage would be: Parameters are: <%HowMuchTime(detail,year,month,day,event)%>.
Detail is a number between 1 and 4 with:
<%HowMuchTime(4,2002,5,10,Started Journal)%> would show:
Started Journal - 2 years, 6 months, and 3 days ago
Copy and paste the code from the nucleus forum at http://forum.nucleuscms.org/viewtopic.php?t=2811 into a file called NP_HowMuchTime.php. Upload the file into the nucleus plugin directory, than install or update the subscription list. Include usage code (shown above) in your skin where you want the output to appear.