• 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

How in Laravel run JavaScript code stored in php variable?

Is there a way to use Foundry Model for Authentification inside Functional Tests?

Laravel excel maatwebsite 3.1 import, date column in excel cell returns as unknown format number. How to solve this?

Apply filter array/return terms

How to get an Array value inside an object in an array Php [duplicate]

PHP -> Next nearest date defined by array of days in week

Confirm Leave on External Links in Wordpress

Laravel database insert with combining array and string

Reducing authentication calls on external API (Laravel 5.6)

Laravel 5.2: Unable to locate factory with name [default]

PHP | "The requested PHP extension bcmath is missing from your system."

Unable to guess the mime type as no guessers are available Laravel 5.2

Add Class in html Dynamically in PHP

Get keys from associative array [duplicate]

Using Associative arrays

About Contact Privacy policy Terms and conditions