Plugin

EE 1
EE 2
DT Plugin

Developer

Vim Interactive, Inc.

3rd Party (Free)

Download v1.3

Compatibility

  • LG Addon Updater
  • Multi Site Manager
  • Stand Alone Entry Form

Requirements

  • jQuery for the Control Panel

Tags

The DT, or date and time, plugin displays dates with formatting and allows you to add days, months, years, hours, minutes and seconds to the current date/time or a static date you set.

The DT Plugin displays dates with formatting and allows you to add days, months, years to the current date or a static date you set.

=============================
Change Log
=============================
—- Version 1.3
Added wrap tag for using with entry loops

—- Version 1.1
Fixed parse bug (thanks Ben)

—- Version 1
Added hour, minute, second to plugin
EE format is now default - use ee_format=“false” for php format

—- Version 0.2
Update to include EE date formats by using ee_format=“true”
Also fixed constructor

—Version 0.1
Initial release
ail any bugs or questions to dev@viminteractive.com


DT v1.0
The DT Plugin displays dates with formatting and allows you to add days, months, years to the current date or a static date you set.

=============================
The Tag
=============================

{exp:dt}

  // Will return the date formatted this way: MM/DD/YYYY

{exp:dt:wrap}

// tag pair used to wrap around entries loop to adding custom dates in to parameters

==============
TAG PARAMETERS
==============

set=[optional]
  Sets the static date that the other parameters will reference. If not set will default to the current date.

{exp:dt set=“01/01/2010”}

  // 01/01/2010

=============================

format=[optional]
  Sets the format of the returned date using the following parameters:
  http://expressionengine.com/user_guide/templates/date_variable_formatting.html

{exp:dt set=“11/03/90” ee_format=“true” format=”%l %M %j, %Y”}

  // Saturday Nov 3, 1990

 
ee_format=[optional]
  if set to ‘false’dt will parse the date using php formating:
  http://php.net/manual/en/function.strftime.php

{exp:dt set=“11/03/90” format=”%A %b %e, %Y”}

  // Saturday Nov 3, 1990
 

=============================

day=[optional]
  Adds or subtracts a value in days to current/set date.

month=[optional]
  Adds or subtracts a value in months to current/set date.

year=[optional]
  Adds or subtracts a value in years to current/set date.

{exp:dt day=“3” month=“1” year=”-1” set=“1/1/2010”}
  //    02/04/09


=============================

hour=[optional]
  Adds or subtracts a value in hours to current/set date.

minute=[optional]
  Adds or subtracts a value in minutes to current/set date.

second=[optional]
  Adds or subtracts a value in seconds to current/set date.


=============================
TROUBLESHOOTING:
=============================

Please email any bugs or questions to dev@viminteractive.com

2.+ Download 1.3 2012-03-30 04:34 PM

DT Plugin Links

This entry was last updated March 30, 2012, 10:45 am.

Disclaimer: Information about ExpressionEngine add-ons is provided as a service to you, the user, and every member of the ExpressionEngine community. Devot:ee is not responsible if you hose, mangle, wreck, or otherwise destroy your EE website by installing an add-on that you found out about at this site, regardless of its rating, Favorites status, commercial or free status, or general popularity. Caveat EEmptor!

1 Review:

Tidy 05.11.12

Tidy
Rating - {addon_rating_average}

Very handy little plugin. Great having the wrap tag available now as well to facilitate using dates as channel entries parameters. Easy to use and avoids turning on php in templates when you want to use start_on or stop_before parameters.