Change language

PHP IntlCalendar getLeastMaximum () function

Syntax:
  • Object Oriented Style
    int IntlCalendar::getLeastMaximum (int $field)
  • Procedural style
    int intlcal_get_least_maximum (IntlCalendar $cal, int $field )
Parameters:This function uses two parameters as above and described below:
  • $cal:this parameter contains an IntlCalendar resource.
  • $field:This parameter contains one of the IntlCalendar date / time field constants. Field constant values ​​are integers and range from 0 to IntlCalendar::FIELD_COUNT.
Return value:This function returns an integer value that represents the field value in field unit on success or FALSE on error.The following program illustrates the IntlCalendar::getLeastMaximum() function in PHP:Program:  
// Set date, time zone ini_set ( ’date.timezone’ , ’ Asia / Calcutta’ ); ini_set ( ’intl.default_locale’ , ’en_US’ );  
// Create a DateTime object $calendar = IntlCalendar::fromDateTime ( ’2019-03-21 09: 19: 29’ );  
var_dump ( $calendar -> getLeastMaximum (IntlCalendar::FIELD_DAY_OF_MONTH), $calendar -> getActualMaximum (IntlCalendar::FIELD_DAY_OF_MONTH ), $calendar -> getMaximum (IntlCalendar::FIELD_DAY_OF_MONTH), $calendar -> getLeastMaximum (IntlCalendar::FIELD_WEEK_OF_YEAR), $calendar -> getActualMaximum (IntlCalendar::FIELD_WEEK_OF_YEAR), $calendar -> getMaximum (IntlCalendar::FIELD_WEEK_OF_YEAR) );
?>
Exit:
int (28 ) int (31) int (31) int (52) int (52) int (53)
Link:https://www.php.net/manual/en/intlcalendar.getleastmaximum.php

Shop

Best laptop for Sims 4

$

Best laptop for Zoom

$499

Best laptop for Minecraft

$590

Best laptop for engineering student

$

Best laptop for development

$

Best laptop for Cricut Maker

$

Best laptop for hacking

$890

Best laptop for Machine Learning

$950

Latest questions

NUMPYNUMPY

psycopg2: insert multiple rows with one query

12 answers

NUMPYNUMPY

How to convert Nonetype to int or string?

12 answers

NUMPYNUMPY

How to specify multiple return types using type-hints

12 answers

NUMPYNUMPY

Javascript Error: IPython is not defined in JupyterLab

12 answers

Wiki

Python OpenCV | cv2.putText () method

numpy.arctan2 () in Python

Python | os.path.realpath () method

Python OpenCV | cv2.circle () method

Python OpenCV cv2.cvtColor () method

Python - Move item to the end of the list

time.perf_counter () function in Python

Check if one list is a subset of another in Python

Python os.path.join () method