• 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

Create a zip file and download it

Creating command to backup MySql database in Laravel

MySQL - Connection failed: No route to host

Insert database rows from columns of data from associative array of indexed arrays

protect my blog content

Mysqli Output to a table

401 Unauthorized only occurring on some pages in Laravel 8

How to redirect to another page after n seconds in wordpress without using javascript?

woocommerce change position of price

PHP file_get_contents function

Laravel s3 upload file with metadata using pre-signed url

Getting public posts of a random user from Facebook API

How to use React Router with Laravel?

WHM Enabling mod_rewrite

Yii2: How to download backup files using spanjeta/yii2-backup?

About Contact Privacy policy Terms and conditions