• 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

Reading input in php from terminal

Edit product hook WooCommerce

What is the function of the (new Date()).getTime() in PHP?

Custom Button next to “ADD TO CART” button of WooCommerce based on Product Type

How do I truncate a decimal in PHP?

How to keep value of selected value after form submission?

Laravel lang slug in url

Issue with laravel eloquent model property

Docker image build with PHP zip extension shows "bundled libzip is deprecated" warning

How to skip cart page on woocomerce for certain products only?

Utf8 encoding issue with Laravel

How to prevent phpmailer sending embedded image as an attachment on Gmail?

Laravel-fopen: failed to open stream: Permission denied

How avoid Moved Permanently The document has moved here

PHP function Not Working As Expected From functions.php Include File

About Contact Privacy policy Terms and conditions