PHP how to get last 6 months first date
You can try following way - for ( $i = 1 ; $i < 7 ; $i ++) { echo date ( ', Y-m-01' , strtotime ( "- $i month" )); }
You can try following way - for ( $i = 1 ; $i < 7 ; $i ++) { echo date ( ', Y-m-01' , strtotime ( "- $i month" )); }
Throttling is a process to rate-limit requests from a particular IP. This can be used to prevent DDOS attacks as well. For throttling, Laravel provides a middleware that can be applied to…
Here is different way to get the date of a selected day ago in PHP . The ways are as bellow - Way - 1: strtotime() will do the trick. Convert your previous date to a Unix timestamp using …
You need to add parentheses around your code: Before: $reference ->frotel_vitrine = empty ( $item ->special) ? null : $item ->special == 2 || $item ->special == 3 ? 'ac…
Error in exception handler: The stream or file "/var/www/laravel/storage/logs/laravel.log" could not be opened in append mode: failed to open stream: Permission denied Disable S…
If this happened first of all lookup phpinfo by phpinfo();. If you not find soap in php info you have to enable soap. To enable soap follow bellow steps - Step 1: Locate php.ini in…
Method 1 : Use DateTime class as bellow $date = new DateTime(); $date->modify('-1 days')->format('Y-m-d'); Method 2: Use strtotime function in date function as bell…
Method 1 : Use DateTime class as bellow $date = new DateTime(); $date->modify('+1 days')->format('Y-m-d'); Method 2: Use strtotime function in date function as bello…