Get the last day of the month from a date

David Carr

1 min read - 31st Aug, 2021

Get the last day of the month from a date

To get the last day of the month use date('t'):

$dueDate = date('t/m/Y', strtotime($row->created_at));

or with Carbon (Laravel example)

$row->created_at->format('t/m/Y');

Domains are often purchased from multiple providers, keeping track of where a domain is and its DNS settings can be tricky. Domain Mapper solves this by listing all your domains in one place. View your DNS settings and receive reminders to renew your domains. Try it today.

0 comments
Add a comment

Copyright © 2024 DC Blog - All rights reserved.