aweitian/carbon

A simple API extension for DateTime.

Installs: 46

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/aweitian/carbon

1.0.0 2018-10-10 09:06 UTC

This package is auto-updated.

Last update: 2025-09-23 23:30:26 UTC


README

composer require aweitian/carbon

示例

$da = new Carbon('2018-10-9');
$da->lastDayOfMonth();//切换到月底
$da->firstDayOfMonth();//切换到月初
$da->format("Y-m-d"); //output

常用API

  • time() Gets the Unix timestamp
  • Carbon::now() 返回当前时间的Carbon对象