PHPackages                             metarisc-odt/base-odt-template - 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. [PDF &amp; Document Generation](/categories/documents)
4. /
5. metarisc-odt/base-odt-template

ActiveLibrary[PDF &amp; Document Generation](/categories/documents)

metarisc-odt/base-odt-template
==============================

ODT rendering

0130↓47.2%PHP

Since May 13Pushed 3w agoCompare

[ Source](https://github.com/metarisc/base-odt-template)[ Packagist](https://packagist.org/packages/metarisc-odt/base-odt-template)[ RSS](/packages/metarisc-odt-base-odt-template/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependenciesVersions (1)Used By (0)

ODT
===

[](#odt)

metarisc-odt/base-odt-template is a library to quickly generate Open Document Text-files using a simple templating mechanism. Spiritual successor to [odtphp](https://github.com/cybermonde/odtphp).

UNDER ACTIVE DEVELOPMENT - EXPECT BC BREAKS

Install
-------

[](#install)

Via Composer

```
$ composer require metarisc-odt/base-odt-template
```

Documentation
-------------

[](#documentation)

### Tags

[](#tags)

Use Date, Field, QrCode and other tags to build your templates.

##### Conditional

[](#conditional)

The Conditional Tag allows to render contents only if condition is true.

```
[IF key]
[/IF key]

```

##### Date

[](#date)

The Date Tag allows to display date values (fr locale only).

```
{date:key}

```

##### Field

[](#field)

The Field Tag allows to display different string values.

```
{field:key}

```

##### Image

[](#image)

The Image Tag allows adding images from URL.

```
{image:key}

```

##### Segment

[](#segment)

The Segment Tag allows to group other tags and iterate array data. The Segment is used as a template to render each row in the data set.

Usage :

```
[SEGMENT key]
[/SEGMENT key]

```

##### QrCode

[](#qrcode)

The QrCode Tag components allow rendering QR codes from any field in the data set.

Usage :

```
{qrcode:key,size:150}

```

Options :

- size : QrCode size in pixel
- margin : Margin in pixel applied to QrCode

##### Markdown

[](#markdown)

The Markdown Tag allows rendering Markdown content.

Usage :

```
{md:key}

```

##### Table

[](#table)

The Simple Table Tag allows rendering a table by duplicating each table row in the document. The field must be an array of associative arrays, where each associative array represents a row in the table. The last row of the table must be the template row, which will be duplicated for each row in the data set.

Usage :

```
[TABLE key]
(...table...)
[/TABLE key]

```

Testing
-------

[](#testing)

```
$ composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Kévin DUBUC](https://github.com/kdubuc)
- [All Contributors](https://github.com/kdubuc/odt/graphs/contributors)

License
-------

[](#license)

The CeCILL-B License. Please see [License File](LICENSE.md) for more information.

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance62

Regular maintenance activity

Popularity14

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity11

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/7674d7c919b73651a0bed70e43868a04077a812ea65f6aea72582fe68522d87b?d=identicon)[HabibErfani](/maintainers/HabibErfani)

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

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

---

Top Contributors

[![LoupMyr](https://avatars.githubusercontent.com/u/100768194?v=4)](https://github.com/LoupMyr "LoupMyr (2 commits)")

### Embed Badge

![Health badge](/badges/metarisc-odt-base-odt-template/health.svg)

```
[![Health](https://phpackages.com/badges/metarisc-odt-base-odt-template/health.svg)](https://phpackages.com/packages/metarisc-odt-base-odt-template)
```

###  Alternatives

[qipsius/tcpdf-bundle

A bundle to easily integrate TCPDF into Symfony

23749.5k](/packages/qipsius-tcpdf-bundle)[radnan/rdn-csv

Laminas module to export and import CSV files

19119.3k](/packages/radnan-rdn-csv)[nilgems/laravel-textract

A Laravel package to extract text from files like DOC, XL, Image, Pdf and more. I've developed this package by inspiring "npm textract".

195.7k](/packages/nilgems-laravel-textract)[akeneo-labs/excel-connector-bundle

Akeneo PIM Excel connector bundle

166.4k](/packages/akeneo-labs-excel-connector-bundle)

PHPackages © 2026

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