date(Y m d)
<?php
// To change the format of an existing date
$old_date_format = "20/03/1999";
$new_data_format = date("Y-m-d H:i:s", strtotime($old_date_format));<?php
// Définit le fuseau horaire par défaut à utiliser. Disponible depuis PHP 5.1
date_default_timezone_set('UTC');
// Affichage de quelque chose comme : Monday
echo date("l");
// Affichage de quelque chose comme : Monday 8th of August 2005 03:12:46 PM
echo date('l jS \of F Y h:i:s A');
// Affiche : July 1, 2000 is on a Saturday
echo "July 1, 2000 is on a " . date("l", mktime(0, 0, 0, 7, 1, 2000));
/* utilise les constantes dans le paramètre format */
// Affichage de quelque chose comme : Wed, 25 Sep 2013 15:28:57 -0700
echo date(DATE_RFC2822);
// Affichage de quelque chose comme : 2000-07-01T00:00:00+00:00
echo date(DATE_ATOM, mktime(0, 0, 0, 7, 1, 2000));
?>
Also in PHP:
- blog post page is_home
- cakephp condition string length > 0
- error in php see
- check if result contains something php
- different days in carbon laravel between different dates
- Laravel Blade Foreach If Empty or Not
- Does ,date('Y-m-d H:i:s') grab local pc or server pc time
- check multiple permission laravel spatie
- Undefined index: $fileName = basename($_FILES["file"]["name"]);file in D:\xampp\htdocs\upload.php on line 12
- 1,458.00 to save as float php
- display_errors php
- check if a string contains specific characters in php
- PHP code for profile page add, edit, delete member?
- check if a function is callable php
- create model, controller and migration in single command laravel
- convert timestamp to date php code
- "Fatal error: Allowed memory size of 1610612736 bytes exhausted (tried to allocate 4096 bytes) in phar://C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleWatchGraph.php on line 52"
- check isset key in array php
- Your Composer dependencies require the following PHP extensions to be installed: dom, xml, xmlwriter
- access violation: 1071 Specified key was too long;
- date format ph
- catch in php
- array_unique trong php
- error reporting all php