• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Laravel Carbon throws error The format separator does not match

phplaraveldatedatetimelaravel-5


PHP Snippet 1:

date("D d M", strtotime("2017-02-09 18:30:00"));
//outputs "Thu 09 Feb"

date("D d M", strtotime($matchArr['matchTime']);

PHP Snippet 2:

date('l j F', strtotime($matchArr['matchTime']))

PHP Snippet 3:

Carbon::createFromFormat('Y-m-d H:i:s', '2017-02-09 18:30:00');

Related Snippets

Laravel s3 upload file with metadata using pre-signed url

getting error while enter Command => php artisan route:list

WooCommerce - unset "<product> removed notice…" on cart page

IlluminateDatabaseQueryException could not find driver [duplicate]

Fatal error: Uncaught mysqli_sql_exception: Unknown database 'test' in ... (How do I fix that? Using PHP)

Doctrine ORM: Excluding Records Based on Values of Nested Relationships

How to pass security cloudflare server with php curl

Laravel websockets AWS EC2 - Connection failed

WooCommerce: Add/display Product or Variation custom field everywhere

How to display table header in every page using FPDF library?

javascript html popup window

Get image type from base64 encoded src string

Get WooCommerce product variation attribute terms in admin products general box

Vimeo API: how to save a vimeo into a subfolder?

Display the WooCommerce product price inside a custom function

About Contact Privacy policy Terms and conditions