PHPackages                             ddeshar/convertthaidate - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. ddeshar/convertthaidate

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

ddeshar/convertthaidate
=======================

A library to convert dates to Thai format

v1.0(3y ago)19mitPHP

Since Feb 20Pushed 3y ago1 watchersCompare

[ Source](https://github.com/ddeshar/Thai-date-Converter)[ Packagist](https://packagist.org/packages/ddeshar/convertthaidate)[ RSS](/packages/ddeshar-convertthaidate/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

Thai-date-Converter
===================

[](#thai-date-converter)

A simple library for converting dates to Thai date format and formatting elapsed time.

Installation
------------

[](#installation)

You can install the library using composer:

```
composer require ddeshar/thai-date-converter
```

Usage
-----

[](#usage)

```
namespace ddeshar\convertthaidate;

require_once __DIR__ . '/vendor/autoload.php';

use ddeshar\convertthaidate\ThaiDateConverter;

$date = '2022-12-31 12:00:00';
$thaiDate = ThaiDateConverter::convert($date, 'th', true, 'dd/mm/yyyy');
echo $thaiDate;
```

### FormatTimeConverter

[](#formattimeconverter)

The `FormatTimeConverter` class provides two methods for converting time values:

- `format_time`: Converts the given number of seconds into a formatted time string in the format of hh:mm.
- `time_ago`: Converts a given timestamp into a human-readable string indicating the time elapsed since that timestamp.

For more information and usage examples, see the [FormatTimeConverter User Manual](UserManual.md#FormatTimeConverter).

### ThaiDateConverter

[](#thaidateconverter)

The `ThaiDateConverter` class provides a method for converting a date string to Thai date format.

- `convert`: Converts a date string to Thai date format.

For more information and usage examples, see the [ThaiDateConverter User Manual](UserManual.md#ThaiDateConverter).

User Manual
-----------

[](#user-manual)

For detailed information on using this library, see the [User Manual](UserManual.md).

Downloads
---------

[](#downloads)

You can download the latest version of the package from the [releases](https://github.com/ddeshar/Thai-date-Converter/releases) page.

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1175d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ecbb84446532b98659f5aa49f038669641e2138ffd47a471d829db74421f1cb1?d=identicon)[ddeshar](/maintainers/ddeshar)

---

Top Contributors

[![ddeshar](https://avatars.githubusercontent.com/u/14323613?v=4)](https://github.com/ddeshar "ddeshar (5 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ddeshar-convertthaidate/health.svg)

```
[![Health](https://phpackages.com/badges/ddeshar-convertthaidate/health.svg)](https://phpackages.com/packages/ddeshar-convertthaidate)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
