Skip to content

cDateISO::WeeksInYear()

Rainer Stötter edited this page May 9, 2017 · 1 revision

Method WeeksInYear( )

 public   mixed libdatephp\cDateISO::WeeksInYear()

WeeksInYear() returns the number of weeks in the actual year

week numbers start with 1. The first week in the year has the number 1

Example:

$dt = new \libdatephp\cDate( 1, 1, 2017 ); assert( $dt->WeeksInYear( ) == 52 );

See also

Clone this wiki locally