date ymd php
date('w'); //gets day of week as number(0=sunday,1=monday...,6=sat)
//note:returns 0 through 6 but as string so to check if monday do this:
if(date('w') == 1){
echo "its monday baby";
}$dateTime = new \DateTime();
/**
* You can get the string by using format
*/
$dateTime->format('Y-m-d H:i:s');
Also in PHP:
- contain in php
- How to fix undefined index: name in PackageManifest.php line 131 error with Composer
- date format H:i:s php
- date format Y-m-d H:i:s
- PHP Fatal error: Uncaught Error: Call to undefined function curl_init
- explain date function in php
- download html content from url php
- date format in php function
- consolelog is it a thing in php
- add 2 days in php
- clear route cache laravel 5.1
- 500 server error laravel
- check if cookie exists php
- clear browser cache in laravel
- find array key in php
- create project laravel 6
- check for a word in a string php
- Interval Between Different Dates
- array_key_exists contains string
- Allowed memory size of 1610612736 bytes exhausted (tried to allocate 4096 bytes) in phar://C:/Users/marvinp/AppData/Local/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleWatchGraph.php on line 52
- count chars in a string php
- convert key to value php
- $date php
- adding header function to href php