date("h:i:sa")
$today = date("F j, Y, g:i a"); // October 30, 2019, 10:42 pm
$today = date("D M j G:i:s T Y"); // Wed Oct 30 22:42:18 UTC 2019
$today = date("Y-m-d H:i:s"); // 2019-10-30 22:42:18(MySQL DATETIME format)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";
}
Also in PHP:
- The main error reporting flags include
- array index exists php
- $s = [1,2,3] for loop use in php
- explode in php
- Auth::routes(['register'=>false]); + laravel
- clear cache in laravel in windows cmd
- clear cache on laravel
- debugger in laravel
- clear browser cache in laravel
- check for a key in array + php
- check if it's the homepage wordpress
- check contain in string php
- How to reload a page using php
- console data in php
- <?php function pre_r($array){ echo '<pre> print_r($array); echo</pre>>'
- explain date function in php
- clean routes cache laravel
- How to fix undefined index: name in PackageManifest.php line 131 error with Composer
- debian php switch version
- create a user using factory laravel
- cache management laravel
- controller in laravel 8
- current date into time
- PHP redireczt