PHP Classes
elePHPant
Icontem

PHP handy date time handler: Compute dates and times of recurring events

Recommend this page to a friend!
  Info   View files Documentation   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2018-08-28 (11 days ago) RSS 2.0 feedNot yet rated by the usersTotal: 157 This week: 20All time: 8,519 This week: 50Up
Version License PHP version Categories
m8 2.0.0Custom (specified...5PHP 5, Time and Date
Description Author

This class can compute dates and times of recurring events.

It can take a given date and calculates the time that passed since that date in a configurable format.

The class can also get the next dates after now with a given interval period.

Recommendations

I need to pick a date and return it to a form
I require the date to return in MySQL/Oracle format

quarter wise, dates,
Braking the dates in quaters and calculating the number of days

Time that passed since timestamp
Calculate time passed from timestamp

What is the best PHP timer countdown class?
I need a php class that will countdown to 24 hours after a given

  Performance   Level  
Name: zinsou A.A.E.Moïse <contact>
Classes: 45 packages by
Country: Benin Benin
Innovation award
Innovation award
Nominee: 17x

Winner: 2x

Details
RemainOrelapse class is a simple class to handle Event recurrences but also time remained to
an event or time elapsed from an event .


class RemainOrElapse

	protected $date;
	public function __construct($date=null)
	
	 take as Argument valid DateTime Object or a valid Date format
		

	public function ago($format="")
	
	return a DateInterval object or a date in the chosen format
	For more information about the format see the PHP DateInterval::format function
		

	public function remained($format="")
	
	return a DateInterval object or a date in the chosen format
	For more information about the format see the PHP DateInterval::format function
		

	public function recurrence($interval,$nth=0,$daysinMonth=30)
	
	return a DatePeriod object 
		

	public function nth_recurrence($interval,$nth=0,$format="",$daysinMonth=30):
	
	return a DateTime object or a date in the chosen format representing the nth date of a recurrene
		For more information about the format see the PHP DateTime::format function


class_alias("RemainOrElapse","Remorelap");


 
For more information on how to specify the Interval see the function PHP DateInterval::CreateFromDateString

For a how to use example see the testremorlap.php file and for more questions or bug reporting
or simply feedback rate this class and use the dedicated forum at PHPclasses.org or simply contact
me at leizmo@gmail.com
  Files folder image Files  
File Role Description
Accessible without login Plain text file license Lic. license
Accessible without login Plain text file readme Doc. readme
Plain text file RemainOrElapse.class.php Class class source
Accessible without login Plain text file testremorlap.php Example example script

 Version Control Unique User Downloads Download Rankings  
 0%
Total:157
This week:20
All time:8,519
This week:50Up