PHP code example of alerrandro / returndate

1. Go to this page and download the library: Download alerrandro/returndate library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

alerrandro / returndate example snippets



Alerrandro\date\DatesNumber\ReturnDatesNumber;

use Alerrandro\date\DatesTextual\ReturnDatesText;

// retora o ano (2022)
$year = ReturnDatesNumber::returnYear();

// retorna o més (01)
$mounth = ReturnDatesNumber::returnMounth();

// retorna o dia (01)
$day = ReturnDatesNumber::returnDay();

// retorna a data por extenso (00/00/0000)
$date = ReturnDatesNumber::returnDate();

// retorna o nome do més (Janeiro)
$nameMounth = ReturnDatesText::returnNameMounth();

// retorna o nome do més de forma curta com três letras (Jan)
$nameMounth = ReturnDatesText::returnNameMounthShort();

// retorna o nome do dia da semana (Segunda-Feira)
$nameWeek = ReturnDatesText::returnNameDayWeek();